Mysql主从同步出现server-id冲突怎么办?

提问者:帅平 问题分类:数据库
Mysql主从同步出现server-id冲突怎么办?
#这个报错出现之后,就看一目了然看到两台机器的 server-id 是一样的。
Last_IO_Error:   Fatal error: The slave I/O thread stops because master and slave have equal MySQL server ids;   these ids must be different for replication to work   (or the --replicate-same-server-id option must be used on slave but this   does not always make sense; please check the manual before using it)
1 个回答
冷清°
冷清°
在主从两台机器上设置不同的 server-id,一般采用的策略是:
服务器 ip 地址的最后一位+本 MySQL 服务的端口号
发布于:2个月前 (05-14) IP属地:
我来回答