Get the App
SLTechnology News&Howtos  ›  Database  › 

Synchronous replication failure caused by binlog_ignore_db

Shulou Source: shulou.com Published: 2022-06-01 05:54:52 10月01日 Update

After using the binlog_ignore_db parameter on MySQL master, all statements executed by mysq-e do not write binlog.

Looking at the MySQL operation manual, ignoring the copy of a library has two parameters:

1 、 binlog_ignore_db

If this parameter is set to master, such as binlog_ignore_db=test, then all operations (add, delete, change) against the library will not be recorded, so that the number of binlog accepted by slave will be reduced, and the network I will be reduced.

2 、 replicate_ignore_db

If this parameter is set on slave, such as replicate_ignore_db=test, then all operations (add, delete, change) under the library will not be performed by the SQL thread, so that although the performance of slave O has not been improved, it ensures the security of slave data.

If the binlog_ignore_db=test parameter is used in master, the executed SQL must use the use command, otherwise the data cannot be synchronized

Suggestion: if you want to ignore a library on slave, use replicate_ignore_db instead of binlog_ignore_db.

Tags: Parameters data synchronization security two commands security recommendations performance manuals operation manuals threads networks statements guarantees faults Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux Microsoft Shulou Tech Info Shulou Information Apple