5.6之前的mysql版本。master info log和relay log info log,都是存储在文件master.info和relay-log.info中。但这个对于服务器掉电的问题,是不能保证relay log info 一致性,为了保证这个crash-safe。5.6推荐一种新的保障方式,把master.info和relay-log.info保存在两张表中。
两张表是mysql.slave_master_info和mysql.slave_relay_log_info表。如果是MySQL 5.6.5 或者更早期。slave_master_info 和 slave_relay_log_info 表 默认使用MyISAM 引擎。所以还得修改成innodb,如下:
ALTER TABLE mysql.slave_master_info ENGINE=InnoDB;
ALTER TABLE mysql.slave_relay_log_info ENGINE=InnoDB;
如果是MySQL 5.6.6之前,还有一个bug如下:
a warning is given when this
occurs, but the slave is allowed to continue starting. (Bug
#13971348) This situation is most likely to occur when upgrading
from a version of MySQL that does not support slave logging tables
to one in which they are supported.