网站制作学习网Database→正文:mysql同步错误Coordinator stopped because there wer
字体:

mysql同步错误Coordinator stopped because there wer

Database 2025/3/18 14:48:00  点击:不统计

原载于:转www.载for网站制作学习asp必.cn究

在mysql 主从同步时,重启了服务器,启动后发现 
start slave
出现:
Coordinator stopped because there were error(s) in the worker(s). The most recent failure being: Worker 5 failed executing transaction 'ANONYMOUS' at source log mysql-bin.007474, end_log_pos 810510902. See error log and/or performance_schema.replication_applier_status_by_worker table for more details about this failure or others, if any.
无法启动slave
 
解决方案,在mysql 命令行运行:
1. 先停止同步
stop slave
查看状态:
SHOW SLAVE STATUS\G
 
2. 查看异常问题:
   SELECT * FROM performance_schema.replication_applier_status_by_worker;
   
 
3. 根据异常原因解决问题,我遇到的是 主键冲突,删除后解决。
或者跳过该从库执行的语句:
   SET GLOBAL sql_slave_skip_counter = 1;   
 
4. 启动从库
   start slave   
 
如果有多个,则重复上面操作,解决后就会自动同步了

原载于:网f站o学a习s制p作.cn

·上一篇:The unit mysql.service has entered the 'failed' state with result 'timeout' >>    ·下一篇:redis windows 密码登录 >>
推荐文章
最新文章