replicate-wild-do-table与replicate-wild-ignore-table
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了replicate-wild-do-table与replicate-wild-ignore-table相关的知识,希望对你有一定的参考价值。
--replicate-wild-do-table=
db_name.tbl_name
Command-Line Format --replicate-wild-do-table=name
Permitted Values Type string
Creates a replication filter by telling the slave thread to restrict replication to statements where any of the updated tables match the specified database and table name patterns. Patterns can contain the “
%
” and “_
” wildcard characters, which have the same meaning as for theLIKE
pattern-matching operator. To specify more than one table, use this option multiple times, once for each table. This works for cross-database updates.通过告诉从线程创建一个复制筛选器来约束任何与指定的数据库和表名称相匹配的更新表相关的语句。模式可以包含“%”和“_”通配符,它与模式匹配算法类似。要指定多个表,使用此选项多次,每个表一次。这是跨数据库更新的工作。
跨数据库这一点是重点,不像replicate-do-db那样,其他的库操作,就不会同步设定的库。这个参数,只要涉及到的该表,就会同步。
--replicate-wild-ignore-table=
db_name.tbl_name
Command-Line Format --replicate-wild-ignore-table=name
Permitted Values Type string
Creates a replication filter which keeps the slave thread from replicating a statement in which any table matches the given wildcard pattern. To specify more than one table to ignore, use this option multiple times, once for each table. This works for cross-database updates.
以上是关于replicate-wild-do-table与replicate-wild-ignore-table的主要内容,如果未能解决你的问题,请参考以下文章