这是我们为客户pipe理的生产实例(EC2)。 停机时间已经5个小时了。 我完蛋了。
故事
今天早上我发现我们的一个客户mysqld进程处于死亡状态。 我做了sudo service mysql start并启动并运行。
日志告知,这是由于桌面崩溃发生的。 通过互联网上的一些参考,我执行了以下命令:
# mysqld was running $ mysqlrepair -A --auto-repair $ mysqlrepair -A -o # By the time the following command was executed, mysqld had stopped $ mysqlrepair -A -c
从那以后,以下命令拒绝启动mysqld
$ sudo service mysql start start: Job failed to start $ sudo mysqld --verbose $ ps aux | grep mysql ubuntu 24124 0.0 0.1 8108 936 pts/0 S+ 04:07 0:00 grep --color=auto mysql $ sudo mysqld_safe 131130 04:09:02 mysqld_safe Logging to '/var/log/mysql/error.log'. 131130 04:09:02 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql 131130 04:09:02 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
/var/log/mysql/error.log中没有当前时间戳记。
$ dmesg | grep mysql [776212.640137] init: mysql main process (24070) terminated with status 1 [776212.640189] init: mysql main process ended, respawning [776213.629832] init: mysql post-start process (24071) terminated with status 1 [776213.650730] type=1400 audit(1385784344.772:92): apparmor="STATUS" operation="profile_replace" name="/usr/sbin/mysqld" pid=24094 comm="apparmor_parser" [776213.745904] init: mysql main process (24098) terminated with status 1 [776213.745957] init: mysql respawning too fast, stopped
configuration文件是: http : //pastebin.com/hbvLGqEM
问题是通过添加到my.cnf来解决的:
innodb_buffer_pool_size = 16M
参考Mike的回答:
https://askubuntu.com/questions/127264/cant-start-mysql-mysql-respawning-too-fast-stopped