Help Center/ Data Replication Service/ Troubleshooting/ Solutions to Failed Check Items/ Database Parameters/ Checking Whether GTID Is Enabled for the Destination Database
Updated on 2024-11-30 GMT+08:00

Checking Whether GTID Is Enabled for the Destination Database

During real-time DR, GTID must be enabled for the destination database. If GTID is disabled for the destination database and a primary/standby switchover is performed on the destination database, the task may fail.

Failure Cause

GTID is disabled on the destination database.

Handling Suggestion

  • If the destination database is an RDS for MySQL DB instance, GTID is enabled by default and cannot be disabled. If GTID is disabled, contact RDS for MySQL O&M personnel.
  • If the destination database version is MySQL 5.5, GTID cannot be set, and DRS cannot be used for disaster recovery. Create a migration task or contact O&M personnel.
  • If the destination database version is MySQL 5.6 or later, set the following parameters to enable GTID in the database configuration file. Then, restart the database for the modifications to take effect.
    Parameters to be configured:
    gtid_mode = on
    log_slave_updates = true 
    enforce_gtid_consistency = on