you can setup your master as:
# master
[mysqld]
port=3306
socket=/var/lib/mysql/mysql.sock
local-infile=1
server-id=1
log-bin
binlog-do-db=test_db
and your slave as:
# slave
[client]
port=3306
socket=/var/lib/mysql/mysql.sock
[mysqld]
port=3306
socket=/var/lib/mysql/mysql.sock
server-id=2
replicate-do-db=test_db
for replication of a specific table, use:
replicate-do-db=test_db.table1
No comments:
Post a Comment