Create a metadata migration
Metadata migrations transfer existing metadata, as well as any subsequent changes made to the source metadata (in the scope of the migration), while Hive Migrator keeps working.
If you're using MariaDB or MySQL, add the JDBC driver to the classpath manually.
Ensure migrations exist for the data (databases and tables) you want to migrate, this is not optional for transactional tables which will not be populated on the target unless the migration for the data exists first.
You need both the data and associated metadata before you can successfully run queries on migrated databases.
Create a metadata migration with the UI
Before creating your metadata migration, create a metadata rule to define it's scope.
- From your Dashboard, select the instance under Instances.
- Under Migrations, select Metadata Migrations.
- Select Create metadata migration.
- Under Migration Name, enter a name for this migration.
- Under Source, select a source Metadata Agent.
- Under Target, select a target Metadata Agent.
If a Databricks Unity Catalog Metastore Agent is selected as target
If a Databricks Workspace Hive Metastore - Legacy Metastore Agent is selected as target
- Under Metadata rules, select a metadata rule to define the scope of the migration.
- Under Grouping, if you don't have any Management Groups, leave the migration unassigned. If you use Management Groups: As an admin user select a management group or leave the migration unassigned. If you are a non-admin user, select your management group.
- Select Start migration automatically to start the migration automatically or leave unselected to start manually after creation.
- Select Create to create the metadata migration.
Metrics shown on the metadata migration content summary page don’t show correct results following certain metadata migration failures. See the Known issue for more information.
Create a metadata migration with the CLI
Migrate metadata from your source metastore to a target metastore using the hive migration add
CLI command.
Define the source and target using the hive agent names detailed in the Connect to metastores section, and apply the hive rule names to the migration.
Follow the command links to learn how to set the parameters and see examples.
Create a new metadata migration:
Apply the
--auto-start
parameter if you would like the migration to start right away.If you don't have auto-start enabled, manually start the migration: