All Products
Search
Document Center

Data Transmission Service:Create a reverse instance

Last Updated:Apr 23, 2024

This topic describes how to use Data Transmission Service (DTS) to create a reverse instance for incremental data synchronization in database disaster recovery scenarios. For more information about the feature, see Create a reverse task.

Background information

DTS allows you to create a reverse instance with a few clicks for a synchronization instance that is running as expected. You can use the reverse instance to synchronize incremental data back from the destination database to the source database. After you switch your workloads from the source database of a synchronization instance to the destination database, you can synchronize the incremental data written to the destination database back to the source database by using a reverse instance. This feature is often used for database disaster recovery.

Prerequisites

  • The source and destination databases of the original synchronization instance are SQL Server databases or MySQL databases, and incremental data synchronization is in progress.

  • The required permissions are granted to the destination database account of the original synchronization instance.

    • If you synchronize data between SQL Server databases, the destination database account of the original synchronization instance must assume the sysadmin role. You can use the system administrator account to grant the permissions to the destination database account by running the EXEC sp_addsrvrolemember @loginame = N'<Account name>', @rolename = N'sysadmin'; command.

    • If you synchronize data between MySQL databases, the destination database account of the original synchronization instance must be granted the REPLICATION CLIENT, REPLICATION SLAVE, SHOW VIEW, and SELECT permissions. For more information, see GRANT Statement.

Limits

  • You can create a reverse instance only for a synchronization instance between SQL Server databases or MySQL databases. You can select only Incremental Data Synchronization for the Synchronization Types parameter when you configure the reverse instance.

  • The data that is directly written to the destination database of the original synchronization instance before a reverse instance is created is not synchronized.

  • A precheck is immediately performed after a reverse instance is created. After the precheck is passed, DTS collects the incremental data but does not write the data to the source database of the original synchronization instance.

  • You can create only one reverse instance for each synchronization instance. After the reverse instance is started, the original synchronization instance cannot be directly started.

  • You cannot create a reverse instance for a cross-border synchronization instance.

Procedure

  1. Go to the Data Synchronization Tasks page.

    1. Log on to the DMS console.

    2. In the top navigation bar, move the pointer over DTS.

    3. In the left-side navigation pane, choose DTS (DTS) > Data Synchronization.

    Note
  2. On the right side of Data Synchronization Tasks, select the region in which you want to create the data synchronization task.

    Note

    If you use the new DTS console, select the region in which you want to create the data synchronization task in the upper-left corner of the page.

  3. Find the synchronization instance that you want to manage, click the 更多设置 icon in the Actions column, and then select Create Reverse Task.

  4. In the Note message, click OK.

    Wait until the precheck of the reverse instance is complete. The instance enters the Performing Initial Synchronization state after the precheck is passed.Status

    Note
    • If Auto Refresh is disabled, you must click the 刷新 icon above the Actions column to refresh the state of the reverse instance.Status

    • If the precheck fails, click View Cause. On the page that appears, click View Details in the Check Result column of the failed check item. Follow the instructions to resolve the issue and run the precheck again.

  5. Pause the original instance.

    1. On the Data Synchronization Tasks page, find the original instance.

    2. In the Actions column, click the 更多设置 icon and select Pause Task.

    3. In the Note message, click OK.

    4. In the The task is paused. message, click OK.

  6. Start the reverse instance.

    1. On the Data Synchronization Tasks page, click the ID of the reverse instance.

    2. Optional. In the left-side navigation pane, click Task Management.

    3. In the Progress section, click the Incremental Write module.

    4. On the Basic Information tab, click Start Incremental Write next to Actions.

    5. In the Note message, click OK.

FAQ

  • Can I create a reverse instance for a migration instance?

    No. You can create a reverse instance only for a synchronization instance between SQL Server databases or MySQL databases.

  • What do I do if the Data Backups item fails the precheck of the reverse instance?

    You must enable log backup in the source database and then run the precheck again. If your source database is a self-managed SQL Server database, click View Details in the Check Result column of the failed check item to view the backup method. If your source database is an ApsaraDB RDS for SQL Server database, you must manually back up your database. For more information, see the Configure manual backups section of the "Back up an ApsaraDB RDS for SQL Server instance" topic.