【在数据库主从备份中遇到的两个报错】??
(1)Last_IO_Error: error connecting to master 'repl@10.0.0.51:3306' - retry-time: 10 ?retries: 4
【解决方案,查看#slave向连接主库建立ms关系的账户密码配置是否有误】
创建复制用户:主:mysql -uroot –pzsb123456 -e "grant replication slave on *.* to 'repl'@'10.0.0.%' identified by 'repl666';"
备:
master_user='repl',
master_password='repl666',
(2)? ? 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'
【解决方案】
1、主->刷新binlog,得到新的binlog,flush logs;show master status;
2、从->stop slave;?
3、change master to master_log_file='binlog.000025',master_log_pos=274;
4、从->start slave;??
5、查看结果 show slave status \G;
友情提醒,master_log_file='binlog.000025'中间不要有空格