This section introduces how to perform data migration on the DTS console.
An example of data migration from MySQL to RDS for MySQL is used to illustrate the procedure. Other storage engines follow a similar procedure.
Create a target RDS database
During data migration, if the database to be migrated is not defined in the target RDS instance, DTS automatically creates it. In some cases where the database name does not comply with the RDS Definition Standard, create the target RDS database on the RDS console before configuring the migration task.
The RDS Definition Standard states the RDS database name can be up to 64 characters in length and consist of lowercase letters, digits, underscore (_), or hyphen (-). It must start with a letter and end with a letter or digit.
Create migration accounts
To create a migration task, first provide the migration accounts of the source instance and the target RDS instance. For different storage engines, specific database access privileges are also required. For more details, refer to the corresponding documents in the DTS User Guide. For example,
With the target RDS database prepared and migration account created, start with configuring the migration task.
Log on to the
Alibaba Cloud DTS console, and enter the Data Migration page.
Click Create Migration Task on the top right corner.
Configure the Source endpoint and target endpoint.
Task Name: By default, DTS automatically generates a name for the migration task. You can edit the name according to your business requirements.
Source Database information: The specific parameters are listed as follows:
Select a Connection Method from Non-encrypted Connection or SSL Secure Connection, and then click Test the Connection to verify the input contents.
Parameter Action Instance Type Select On-premises databases. Instance Region Select the region in closest geographic proximity to the source instance. Database Engine Select MySQL. Host Name or IP Address Enter the MySQL database connection string. Port Enter the MySQL database listener port. Database Account Enter the MySQL database account name. Database Password Enter the MySQL database account password.
Target Database information: The specific parameters are listed as follows：
Click Test the connection to verify the input contents.
Parameter Action Instance Type Select RDS Instance. Instance Region Select the region of the RDS instance. RDS Instance ID Select the target RDS instance ID. Database Account Enter the access account name of the RDS instance database. Database Password Enter the access account password of the RDS instance database.
Configure Migration type and migration objects.
Migration Type: The migration type includes Schema migration, Existing data migration, and Incremental replication.
- For existing data migration, select schema migration and existing data migration.
- For zero downtime data migration, select schema migration, existing data migration, and incremental replication.
Migration Objects: The migration objects include database, table, and column.
- By default, the object names are the same as in the source and target database.
- To use the object name mapping function provided by DTS, refer to Object name mapping.
Perform Pre-check before the migration task is started.
- If the pre-check fails, click Failed to check the details of the failed items.
- Click View to look up the reason and solution. Troubleshoot the issues and continue to perform pre-check until the pre-check is successful.
Start the migration task.
After the pre-check passes, you can start the migration task. When the task is started, you can view the migration status and progress in the task list.