【mysql、innodb】mysql启动失败,出现crash
不知道什么时候,vps上面的mysql不启动了,后来果断来了个apt-get upgrade。还是无解,发现mysql.err为空。怎么弄头看不明白。
后来查看/var/log/syslog,发现如下记录:
May 28 07:36:53 emhct mysqld: 160528 7:36:53 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. P$
May 28 07:36:53 emhct mysqld: 160528 7:36:53 [Note] /usr/sbin/mysqld (mysqld 5.5.49-0+deb7u1) starting as process 2208 …
May 28 07:36:53 emhct mysqld: 160528 7:36:53 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future$
May 28 07:36:53 emhct mysqld: 160528 7:36:53 [Note] Plugin ‘FEDERATED’ is disabled.
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: The InnoDB memory heap is disabled
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Mutexes and rw_locks use GCC atomic builtins
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Compressed tables use zlib 1.2.7
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Using Linux native AIO
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Initializing buffer pool, size = 128.0M
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Completed initialization of buffer pool
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: highest supported file format is Barracuda.
May 28 07:36:53 emhct mysqld: InnoDB: The log sequence number in ibdata files does not match
May 28 07:36:53 emhct mysqld: InnoDB: the log sequence number in the ib_logfiles!
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Database was not shut down normally!
May 28 07:36:53 emhct mysqld: InnoDB: Starting crash recovery.
May 28 07:36:53 emhct mysqld: InnoDB: Reading tablespace information from the .ibd files…
May 28 07:36:53 emhct mysqld: InnoDB: Restoring possible half-written data pages from the doublewrite
May 28 07:36:53 emhct mysqld: InnoDB: buffer…
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: ERROR: We were only able to scan the log up to
May 28 07:36:53 emhct mysqld: InnoDB: 16701665280, but a checkpoint was at 16701665306.
May 28 07:36:53 emhct mysqld: InnoDB: It is possible that the database is now corrupt!
May 28 07:36:53 emhct mysqld: 160528 7:36:53 InnoDB: Assertion failure in thread 3064944864 in file fut0lst.ic line 83
May 28 07:36:53 emhct mysqld: InnoDB: Failing assertion: addr.page == FIL_NULL || addr.boffset >= FIL_PAGE_DATA
mysql居然crash了,后来网上了一下,发现好像是innodb顺坏了,简单扫描了mysql官方文档,看的云里雾里。
最终,把mysql数据库存放目录下的ibdata1、ib_*文件删除后,mysql正常启动。