Migrate metadata
Once you have created a metadata target, you're ready to migrate metadata.
Your source metadata agent will, by default, use Listening mode. Find out more information on agent modes, and how to change them in Manage metadata changes.
- Migrate metadata with the Azure Portal
- Migrate metadata with the CLI
To create a metadata migration:
In the Azure Portal, navigate to the LiveData Migrator resource page.
From the LiveData Migrator menu on the left, select Metadata Migrations.
Select Create.
Complete the details under the Basics section:
- Migration Name: enter the reference name to use for the metadata migration.
- Metadata Target: select the metadata target to send metadata to.
- Database pattern: enter a database query pattern. Databases with names following this pattern will be transferred from the source filesystem.
- Table pattern: a database table query pattern. Tables in the database with names following this pattern will be transferred from the source filesystem.
noteDatabase and table patterns can use an asterisk symbol (*) for any characters or a pipe symbol (|) for a choice.
For example, a database pattern of 'test*' migrates any database with 'test' at the beginning of its name, such as
test01
,test02
, andtest03
.
A table pattern of 'emp*|*ees' migrates all tables namedemployees
.Specify only
*
to migrate all databases or tables.- Automatically Start Migration: Select this to start the metadata migration automatically after creation.
Select Review and create.
Select Create.
View the metadata migration
- In the Azure Portal, navigate to the LiveData Migrator resource page.
- From the LiveData Migrator menu on the left, select Metadata Migrations.
- Select the migration to view it.
Start and stop metadata migrations
- In the Azure Portal, navigate to the LiveData Migrator resource page.
- From the LiveData Migrator menu on the left, select Metadata Migrations.
- Select the metadata migration and select Start or Stop as required.
Delete a metadata migration
- In the Azure Portal, navigate to the LiveData Migrator resource page.
- From the LiveData Migrator menu on the left, select Metadata Migrations.
- Select the metadata migration and select Delete.
You can't add exclusions to or remove them from metadata migrations. You also can't create one-time metadata migrations, unlike data migrations. See Create a one-time migration for more information.
Create a metadata migration
The following command creates a metadata migration using a target you created. You can have multiple metadata migrations in any LiveData Migrator instance.
az livedata migrator metadata-migration create --resource-group <resource_group> --migrator-name <migrator_name> --metadata-target <target_name> --migration-name <new_metadata_migration_name> --db-name-pattern "*" --table-name-pattern "*"
During the creation of a metadata migration, you can start a metadata migration right away, or start it manually later. Enter the --auto-start
parameter to start the metadata migration immediately after creation.
az livedata migrator metadata-migration create --resource-group <resource_group> --migrator-name <migrator_name> --metadata-target <target_name> --migration-name <new_metadata_migration_name> --db-name-pattern "*" --table-name-pattern "*" --auto-start
Use --db-name-pattern "*"
and --table-name-pattern "*"
to migrate all databases or tables, respectively.
View a metadata migration
If you want to see how a metadata migration is progressing, you can check its status by running the following command. See the migrationStatus property in the response for the status of the metadata migration.
az livedata migrator metadata-migration show -g <resource_group> --migrator-name <migrator_name> --migration-name <migration_name>
Start a metadata migration
Run the following command to start a metadata migration that has been created but not started automatically. You can also use this command on a stopped metadata migration.
az livedata migrator metadata-migration start --resource-group <resource_group> --migrator-name <migrator_name> --migration-name <migration_name>
Stop a metadata migration
Run the following command to stop a metadata migration.
az livedata migrator metadata-migration stop --resource-group <resource_group> --migrator-name <migrator_name> --migration-name <migration_name>
Resume a metadata migration by starting it.
Delete a metadata migration
Run the following command to delete a metadata migration.
az livedata migrator metadata-migration delete --resource-group <resource_group> --migrator-name <migrator_name> --migration-name <metadata_migration_name>
You can't add exclusions to or remove them from metadata migrations. You also can't create one-time metadata migrations.
Metadata migration states
CREATED
: The metadata migration has been created successfully but has not yet been run.RUNNING
: The metadata migration is scanning through source metadata content and transferring it to the target, as well as responding to change notifications from the source.STOPPED
: The metadata migration's data transfer has been halted. When restarted, the metadata migration will continue from the point where it stopped.
Troubleshooting
If you're having problems migrating metadata, you can find solutions in the troubleshooting section.