记录一下处理Windows因为断电导致mysql服务启动失败的处理过程
- 问题日志
- 解决方法
问题日志
因为mysql是使用宝塔面板安装,启动服务时提示
后来去安装目录下data文件夹下找到mysql_error.log日志文件,发现以下错误
Binlog has bad magic number; It’s not a binary log file that can be used by this version of MySQL
Can’t init tc log
解决方法
开始在网络上搜索需要删除mysql-bin.XXXXX01类似文件,但是我删除后还是失败,后来在https://dba.stackexchange.com/questions/27749/binlog-has-bad-magic-number这个文章的提示下,需要删除mysql-bin.index文件,因为急需恢复mysql服务,所以将mysql-bin.XXXX01类似文件以及mysql-bin.index全部删除后,重启服务正常,暂时未排查删除后的影响。