mysql innodb问题

mysql innodb问题

在我的 mysql 错误日志文件中看到以下内容:

InnoDB: Error: log file ./ib_logfile0 is of different size 0 5242880 bytes
InnoDB: than specified in the .cnf file 0 268435456 bytes!
110927 18:36:37 [ERROR] Plugin 'InnoDB' init function returned error.
110927 18:36:37 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.

如何轻松修复此问题?

谢谢!

答案1

正如错误所说,在你的 my.cnf 中你必须有 innodb_log_file_size= 256M。

因此,请停止 MYSQL 服务器,重命名 ib_logfile0 和 ib_logfile1 文件,然后重新启动服务器。它应该会创建两个新文件,每个文件大小为 256M。

你是如何陷入这种情况的是一个重要的问题。尝试恢复旧备份?即在 my.cnf 中更改 innodb_log_file_size 之前。

相关内容