2.Slave2主机上查看是否同步
[root@Slave2 ~]# mysql -e "SELECT * FROM hellodb.teachers;" +-----+---------------+-----+--------+ | TID | Name | Age | Gender | +-----+---------------+-----+--------+ | 1 | Song Jiang | 45 | M | | 2 | Zhang Sanfeng | 94 | M | | 3 | Miejue Shitai | 77 | F | | 4 | Lin Chaoying | 93 | F | | 5 | Tang San | 30 | M | #已经同步 +-----+---------------+-----+--------+ 其他事项当原主节点被修复后,将其添加为从节点使用。
Linux公社的RSS地址:https://www.linuxidc.com/rssFeed.aspx