debezium을 이용해 CDC(change data caputre) 기능을 접목하려 할 때.  GTID와 binlog 설정에 도움이 되는 설정(테스트 환경 설정)은 다음과 같다.



server-id         = 111

log_bin           = mysql-bin

expire_logs_days  = 1

gtid-mode         = ON

enforce-gtid-consistency = ON

binlog_format     = row
enforce_gtid_consistency  = on

#binlog_cache_size

#max_binlog_size





snapshot 모드를 위해 select, reload, show databases 권한이..

connector 최소 연결을 위해 replication slave, replication client 권한이 필요하다.



GRANT SELECT, RELOAD, SHOW DATABASES, REPLICATION SLAVE, REPLICATION CLIENT ON *.* TO 'debezium' IDENTIFIED BY 'dbz';




참고 


https://github.com/debezium/docker-images/blob/master/examples/mysql/0.8/mysql.cnf


https://dev.mysql.com/doc/refman/5.5/en/replication-options-binary-log.html


https://debezium.io/docs/connectors/mysql/#topic-names

Posted by '김용환'
,