Configuring the MySQL database for replication

You must enable GTID and binary logging by ensuring that the following entries exist in the my.cnf file (Linux and UNIX) or my.inf file (in Windows).


   log-bin=path to binary logs
   log-bin-index=path to binary logs windex 
   binlog_format=row
   binlog_row_image=full
   enforce_gtid_consistency = ON
   gtid_mode = ON
   log_slave_updates = TRUE
   server_id = integer value of 1 or higher
   show_compatibility_56 = ON
  • The show_compatibility_56 entry is only required for MySQL v5.7.
  • Note: binlog_row_image=full is the default value, and this is the only value that is supported by CDC Replication.

Note: The above contents are MySQL configuration settings and any terms or parameter names are strictly those provided by MySQL.
Note: Download MySQL Binary Logs from a Remote Server

CDC requires access to MySQL binary logs to replicate changes from the source database. When you install CDC on a server different from the database server, you download the MySQL binary logs from the remote database server to the local CDC server. You use the mysqlbinlog utility that the MySQL client provides to download the binary logs.

You install the MySQL client on the local server where you run CDC. During CDC configuration, you set the binary log path to the directory where you store the downloaded binary logs on the local server.

CDC Replication Engine for MySQL database latency depends on the amount of time required by the mysqlbinlog utility to copy or download to the CDC local server. Latency can rise as the time required to copy or download binary logs increases.

For instance, this command copies and downloads the MySQL binary logs in live mode from the source server, starting from binlog.000130: mysqlbinlog --read-from-remote-server --host=host_name --raw --stop-never binlog.000130

For more information about the command mysqlbinlog, see MySQL documentation page.