All Products
Search
Document Center

Migrate data between databases with different names in the same instance

Last Updated: May 28, 2019

Scenarios

This topic describes data migration between databases with different names under the same RDS instance using Data Transmission Service (DTS). The topic is based on the example of using DTS to migrate the amptest database of the source instance to the jiangliu_amptest database of the target RDS instance. You can learn how to use DTS to migrate data between databases with different names under the same RDS instance.

* Note: The steps for configuring the migration remain the same when the source and target instance types are not RDS.

Prerequisites

  • An RDS account. Different database types. Different permissions for the migration account. For more information about specific permission requirements, see Data migration.

  • Create the amptest database and the jiangliu_amptest database under the same RDS instance.

Procedure

  1. Log on to the Data Transmission Service (DTS) console with the Alibaba account to which the target RDS instance belongs. Click Create Migration Task in the upper-right corner of the console to start task configuration.

  2. Configure the connection information of the instance, as shown in the following figure:

    Set the migration task name and configure the connection information about the source and target instances in migration. Specifically:

    • Task name

    By default, DTS generates a name for every task automatically. The task name is not required to be unique. You can modify the name. We recommend that you configure a name indicating the specific services of the task for convenient identification.

    • Source instance connection information

      • Instance type: Select DRDS Instance.
      • RDS instance ID: Configure the ID of the RDS instance
      • Database account: the RDS instance access account
      • Database password: the password of the preceding RDS access account
    • Target instance connection

      • Instance type: Select DRDS Instance.
      • RDS instance ID: to configure the ID of the RDS instance
      • Database account: the RDS instance access account
      • Database password: the password of the above RDS access account
  3. Configure the migration type and migration objects, and select the migration database amptest. Map the amptest database of the source instance to the jiangliu_amptest database of the target RDS instance, as shown in the following figure:

![Cross-database Migration_Instance Connection]

4.To configure the database name mapping, find the selected objects list on the right, and click the Edit button that appears. Click Edit to enter the configuration page of database name mapping, as shown in the following figure:

![Cross-database Migration_Object Name Mapping]

5.When the configuration is complete, click Pre-check and Start as shown in the following figure. Pre-check is performed before migration tasks start:

  • Pre-check successful: Migration starts successfully.
  • Pre-check failed: Click the button after the specific check to view failure details, fix the errors accordingly, and then perform pre-check again.

Cross-database migration_pre-check

After the pre-check is passed, you can start the migration task.

You have completed data migration between databases with different names under the same RDS instance using DTS.