mysql启动失败 日志InnoDB: Ignoring the redo log due to missing MLOG_CHECKPOINT between the checkpoint 3485
mysql报错Ignoring the redo log due to missing MLOG_CHECKPOINT between
mysql版本:5.7.33
系统版本:ubuntu16.04
由于电脑突然关闭,跑在VMware里面的mysql在重启电脑后启动失败
错误日志:
2021-04-13T00:40:53.314298Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2021-04-13T00:40:53.315330Z 0 [ERROR] InnoDB: Ignoring the redo log due to missing MLOG_CHECKPOINT between the checkpoint 3485392909 and the end 3485392896.
2021-04-13T00:40:53.315377Z 0 [ERROR] InnoDB: Plugin initialization aborted with error Generic error
2021-04-13T00:40:53.920349Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2021-04-13T00:40:53.920553Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2021-04-13T00:40:53.920580Z 0 [ERROR] Failed to initialize builtin plugins.
2021-04-13T00:40:53.920591Z 0 [ERROR] Aborting
2021-04-13T00:40:53.920605Z 0 [Note] Binlog end
2021-04-13T00:40:53.921875Z 0 [Note] /usr/sbin/mysqld: Shutdown complete
解决办法有两个
第一个
设置innodb_force_recovery=6,然后启动mysql,能够顺利启动mysql
由于损坏的这个库是从库,所以显示无法初始化master info表
由于mysql库里有几个表都显示找不到表空间,那么会存在丢失数据的风险
第二个
把实例的所有ib_logfilex文件删除,再启动mysql,能够顺利启动
Set
innodb_log_checksums = ON
on master and slave.Remove
rm /var/lib/mysql/ib_logfile*
.Restart.