Data Transmission Service

Preparing for MySQL Instances on Other Cloud Platforms

2023-10-30 08:41:40

Network

Configure VPC security policies.

You need to allow the public IP address you configured for the DTS instance to access the VPC where the third-party cloud database instance resides. In most cases, you can modify the network ACL or configure the security group for the database instance to enable the access. For more information, see the official database documentation provided by the corresponding cloud service provider.

Configure the IP address trustlist for the database.

You need to allow the public IP address you configured for the DTS instance to remotely access the database. The method to configure an IP address trustlist for a database may vary depending on the database type. For more information, see the relevant official database documentation.

Database Accounts and Permissions

Required Permissions

  1. Query permissions on MySQL databases.

  2. Query permissions on the databases to be migrated.

  3. Certain global permissions.
    RELOAD
    LOCK TABLES
    REPLICATION CLIENT

    REPLICATION SLAVE

    SHOW VIEW

    PROCESS

  4. To migrate an entire instance, the query permissions on all databases in the source instance are required.

Sample Statement for Granting Permissions

GRANT SELECT ON mysql. TO 'Account used for migration '@'%';*

GRANT SELECT ON Source database. TO 'Account used for migration'@'%';*

GRANT RELOAD, LOCK TABLES, REPLICATION CLIENT, REPLICATION SLAVE, SHOW VIEW, PROCESS ON . TO 'Account used for migration'@'%';

Database Configuration

The binlog feature must be enabled for the source MySQL database, and the row-based format is used for binary logging.

If the storage space is sufficient, store the source database binlogs as long as possible. The recommended retention period is three days.

If the value of the expire_logs_days parameter for the source database is 0, the migration may fail.

If you need to perform incremental data migration, you must specify a server ID for your source MySQL database. If the version of the source MySQL database is equal to or earlier than 5.6, the server ID can be from 2 to 4294967296. If the version is equal to or later than 5.7, the server ID can be from 1 to 4294967296.

We recommend that you enable global transaction identifier (GTID) for the source database. If GTID is disabled for the source database, DTS does not support primary-standby switchover for high availability because DTS tasks will be interrupted during primary-standby switchover and cannot be restored due to offset discontinuity.


IIGUlg128QTj