昨天晚上10点多发现mysql挂了,也不知道是什么时候挂的,然后翻出昨天mysql的错误日志,下面是昨天全部的记录
120828 12:31:52  InnoDB: Started; log sequence number 0 44243
120828 12:31:52 [Note] Recovering after a crash using mysql-bin
120828 12:31:52 [Note] Starting crash recovery...
120828 12:31:52 [Note] Crash recovery finished.
120828 12:31:59 mysqld_safe Number of processes running now: 0
120828 12:31:59 mysqld_safe mysqld restarted
120828 12:32:00 [Note] Plugin 'FEDERATED' is disabled.
120828 12:32:00 [Note] Plugin 'ndbcluster' is disabled.
120828 12:32:02  InnoDB: Initializing buffer pool, size = 8.0M
120828 12:32:02  InnoDB: Completed initialization of buffer pool
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
120828 12:32:02  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
120828 12:32:08  InnoDB: Started; log sequence number 0 44243
120828 12:32:08 [Note] Recovering after a crash using mysql-bin
120828 12:32:09 [Note] Starting crash recovery...
120828 12:32:09 [Note] Crash recovery finished.
120828 12:32:09 [Note] Event Scheduler: Loaded 0 events
120828 12:32:09 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.
Version: '5.1.54-log'  socket: '/tmp/mysql.sock'  port: 3306  Source distribution
120828 12:32:17 mysqld_safe Number of processes running now: 0
120828 12:32:17 mysqld_safe mysqld restarted
120828 12:32:18 [Note] Plugin 'FEDERATED' is disabled.
120828 12:32:18 [Note] Plugin 'ndbcluster' is disabled.
120828 12:32:18  InnoDB: Initializing buffer pool, size = 8.0M
120828 12:32:18  InnoDB: Completed initialization of buffer pool
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
120828 12:32:18  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
120828 12:32:18  InnoDB: Started; log sequence number 0 44243
120828 12:32:18 [Note] Recovering after a crash using mysql-bin
120828 12:32:18 [Note] Starting crash recovery...
120828 12:32:18 [Note] Crash recovery finished.
120828 12:32:19 [Note] Event Scheduler: Loaded 0 events
120828 12:32:19 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.
Version: '5.1.54-log'  socket: '/tmp/mysql.sock'  port: 3306  Source distribution
120828 12:32:54 mysqld_safe Number of processes running now: 0
120828 12:32:54 mysqld_safe mysqld restarted
120828 12:32:54 [Note] Plugin 'FEDERATED' is disabled.
120828 12:32:54 [Note] Plugin 'ndbcluster' is disabled.
120828 12:32:54  InnoDB: Initializing buffer pool, size = 8.0M
120828 12:32:54  InnoDB: Completed initialization of buffer pool
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
120828 12:32:54  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
120828 12:32:59 mysqld_safe mysqld from pid file /usr/local/mysql/var/li519-164.pid ended
120828 14:52:35 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
120828 14:52:35 [Note] Plugin 'FEDERATED' is disabled.
120828 14:52:35 [Note] Plugin 'ndbcluster' is disabled.
120828 14:52:35  InnoDB: Initializing buffer pool, size = 8.0M
120828 14:52:35  InnoDB: Completed initialization of buffer pool
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
120828 14:52:35  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
120828 14:52:36  InnoDB: Started; log sequence number 0 44243
120828 14:52:36 [Note] Recovering after a crash using mysql-bin
120828 14:52:37 [Note] Starting crash recovery...
120828 14:52:37 [Note] Crash recovery finished.
120828 14:52:37 [Note] Event Scheduler: Loaded 0 events
120828 14:52:37 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.
Version: '5.1.54-log'  socket: '/tmp/mysql.sock'  port: 3306  Source distribution
120828 14:53:05 mysqld_safe Number of processes running now: 0
120828 14:53:05 mysqld_safe mysqld restarted
120828 15:04:00 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
120828 15:04:01 [Note] Plugin 'FEDERATED' is disabled.
120828 15:04:01 [Note] Plugin 'ndbcluster' is disabled.
120828 15:04:01  InnoDB: Initializing buffer pool, size = 8.0M
120828 15:04:01  InnoDB: Completed initialization of buffer pool
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
120828 15:04:01  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
120828 15:04:01  InnoDB: Started; log sequence number 0 44243
120828 15:04:01 [Note] Recovering after a crash using mysql-bin
120828 15:04:01 [Note] Starting crash recovery...
120828 15:04:01 [Note] Crash recovery finished.
120828 15:04:01 [Note] Event Scheduler: Loaded 0 events
120828 15:04:01 [Note] /usr/local/mysql/libexec/mysqld: ready for connections.
Version: '5.1.54-log'  socket: '/tmp/mysql.sock'  port: 3306  Source distribution
120828 15:04:02 mysqld_safe A mysqld process already exists

解决方案 »

  1.   


    ps -aux | grep mysqld
    你的系统中已经启动了一个mysqld了。
      

  2.   


    这个有点奇怪,应该是昨天下午15:04:02左右挂了吧,晚上的时候,有人说网站打不开,于是我发现数据库挂了,进ssh后执行ps -aux,并没有发现mysql进程,于是启动mysql就好了。下午15:04:02左右我并没有手工操作,灵异事件啊
      

  3.   

    没有mysqld进程,重启mysql服务器。
      

  4.   

    查看一下进程
    ps -aux | grep mysqld