innodb 日志文件异常引起innodb 启动失败

innodb 日志文件异常引起innodb 启动失败

110531 09:19:16 mysqld_safe Starting mysqld daemon with databases from /data/mysql_data
InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use GCC atomic builtins
InnoDB: Compressed tables use zlib 1.2.3
110531  9:19:17  InnoDB: Initializing buffer pool, size = 1.0G
110531  9:19:17  InnoDB: Completed initialization of buffer pool
110531  9:19:17  InnoDB: Log file ./ib_logfile0 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile0 size to 10 MB
(日志文件异常)


InnoDB: Database physically writes the file full: wait...
InnoDB: Error: all log files must be created at the same time.
InnoDB: All log files must be created also in database creation.
InnoDB: If you want bigger or smaller log files, shut down the
InnoDB: database and make sure there were no errors in shutdown.
InnoDB: Then delete the existing log files. Edit the .cnf file
(需要删除redo文件,重建)
InnoDB: and start the database again.
110531  9:19:17 [ERROR] Plugin 'InnoDB' init function returned error.
110531  9:19:17 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
110531  9:19:17 [ERROR] Can't open and lock privilege tables: Table 'mysql.servers' doesn't exist
110531  9:19:17 [ERROR] Column count of mysql.db is wrong. Expected 22, found 20. The table is probably corrupted
110531  9:19:17 [ERROR] mysql.user has no `Event_priv` column at position 29
110531  9:19:17 [ERROR] Cannot open mysql.event
110531  9:19:17 [ERROR] Event Scheduler: An error occurred when initializing system tables. Disabling the Event Scheduler.
110531  9:19:17 [Note] /usr/local/mysql-5.1.57/bin/mysqld: ready for connections.
Version: '5.1.57-log'  socket: '/tmp/mysql.sock'  port: 3306  Source distribution
110531  9:22:09 [Warning] Statement may not be safe to log in statement format. Statement: ALTER TABLE general_log
  MODIFY event_time TIMESTAMP NOT NULL,
  MODIFY user_host MEDIUMTEXT NOT NULL,
  MODIFY thread_id INTEGER NOT NULL,
  MODIFY server_id INTEGER UNSIGNED NOT NULL,
  MODIFY command_type VARCHAR(64) NOT NULL,
  MODIFY argument MEDIUMTEXT NOT NULL
110531  9:22:09 [Warning] Statement may not be safe to log in statement format. Statement: ALTER TABLE slow_log
  MODIFY start_time TIMESTAMP NOT NULL,
  MODIFY user_host MEDIUMTEXT NOT NULL,
  MODIFY query_time TIME NOT NULL,
  MODIFY lock_time TIME NOT NULL,
  MODIFY rows_sent INTEGER NOT NULL,
  MODIFY rows_examined INTEGER NOT NULL,
  MODIFY db VARCHAR(512) NOT NULL,
  MODIFY last_insert_id INTEGER NOT NULL,
  MODIFY insert_id INTEGER NOT NULL,
  MODIFY server_id INTEGER UNSIGNED NOT NULL,
  MODIFY sql_text MEDIUMTEXT NOT NULL

  解决办法:

删除ib_logfile0 ib_logfile1 文件

重启mysql服务。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值