1: The official explanation is: in a master-slave synchronization environment, REPLICATE-IGNORE-DB is used to set up libraries that do not need to be synchronized. The explanation is too simple, but there are still a lot of holes in it.
Setting filter rules is not recommended on production libraries. If you want to set it, then use replicate_wild_ignore_table:mysql.%. The experiment is very simple, as follows
First case from library: replicate-ignore-db = mysql Main library: Use Mysqlcreate TABLE test.testrepl1 (id int (5)) Engine=innodb DEFAULT charset= UTF8; not synchronized from library. Pit the second case from library: replicate-ignore-db = mysql Main library: Use Testcreate TABLE mysql.testrepl2 (id int (5)) Engine=innodb DEFAULT charset= UTF8; not synchronized from library. In the third case, use testupdate mysql.user set user = ' Testuser5 ' where user = ' TestUser1 '; the fourth case is synchronized from the library grant all on *. * to [email Protec Ted] '% ' identified by ' Ge0513.hudie '; sync from library Second class: Replicate_wild_ignore_table:mysql.% fifth case Main Library: use Testupdate mysql.user Set user = ' TestUser1 ' where user = ' testuser5 '; not synchronized from library. Sixth Case Main Library: Grant all on * * to [email protected] '% ' identified by ' Ge0513.hudie '; no sync from library.
MySQL Replicate-ignore-db Detailed