How to setup CDC MySQL
To setup CDC between your MySQL database and Peaka Big Table, you need:
In your MySQL primary database, create a database user that must have appropriate permissions on all databases for which the Peaka CDC captures changes.
CREATE USER <username>@'%' IDENTIFIED WITH mysql_native_password BY 'password';
GRANT SELECT, RELOAD, SHOW DATABASES, REPLICATION SLAVE, REPLICATION CLIENT ON *.* TO <username>@'%';
FLUSH PRIVILEGES;
log-bin
option is already on:// for MySql 5.x
mysql> SELECT variable_value as "BINARY LOGGING STATUS (log-bin) ::"
FROM information_schema.global_variables WHERE variable_name='log_bin';
// for MySql 8.x
mysql> SELECT variable_value as "BINARY LOGGING STATUS (log-bin) ::"
FROM performance_schema.global_variables WHERE variable_name='log_bin';
OFF
, configure your MySQL server configuration file with the following properties, which are described in the table below:server-id = 223344 # Querying variable is called server_id,
e.g. SELECT variable_value FROM information_schema.global_variables
WHERE variable_name='server_id';
log_bin = mysql-bin
binlog_format = ROW
binlog_row_image = FULL
expire_logs_days = 10