项目场景:
mysql主从同步
问题描述:
主从同步遇到同步日志紊乱Master_SSL_Verify_Server_Cert: No
Last_IO_Errno: 1236
Last_IO_Error: Got fatal error 1236 from master when reading data from binary log: 'Could not find first log file name in binary log index file'
Last_SQL_Errno: 0
原因分析:
分析由于binlog索引导致解决方案:
1、登录主->刷新binlog,得到新的binlog2、登录从->stop slave;
3、change master to master_log_file='binlog.000005',master_log_pos=154;
4、start slave;
5、查看结果 show slave status \G; ![修复后slave状态](https://img-blog.csdnimg.cn/24ccf572ce8d49cf99f8c5a54e6fae9b.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBA6Z2g6L-R5YWo5qCI,size_20,color_FFFFFF,t_70,g_se,x_16#pic_center)