mysql之主主同步

数据库mysql之主主同步,很多情况下需要数据之间数据进行更新。

创建用户

A:
show master status;
chang master to
matser_host='B',
master_port=3306,
master_user='rep',
masetr_password='xxxxxx',
master_log_file='mysql-bin.000013',
master_log_pos=12344;

start slave;

show slave status\G;

B:

show master status;
chang master to
matser_host='A',
master_port=3306,
master_user='rep',
masetr_password='xxxxxx',
master_log_file='mysql-bin.000013',
master_log_pos=12344;

start slave;

show slave status\G;

  

posted @ 2021-10-12 16:15  卜闻卜问卜听卜在乎  阅读(42)  评论(0编辑  收藏  举报