mysql無法啟動的解決辦法
MySQL無法啟動
在停止mysql之後,執行了一些操作(如修改主機名),重新啟動 mysql,發現起不來。
[root@www ~]$ service mysql start Starting MySQL..^[[A.................................................................................................. ERROR! The server quit without updating PID file (/disk/mysql/www.pid). [root@www ~]$ service mysql stop ERROR! MySQL server PID file could not be found! [root@www ~]$ service mysql stop ERROR! MySQL server PID file could not be found! [root@www ~]$ service mysql start Starting MySQL.................. 還是老樣子,只好 Ctr+C 掉。 [root@www ~]$
實在是啟動不了,看一下日誌:/disk/mysql/www.err
120608 09:56:17 mysqld_safe Starting mysqld daemon with databases from /disk/mysql 120608 9:56:17 [Note] Plugin 'FEDERATED' is disabled. 120608 9:56:17 InnoDB: The InnoDB memory heap is disabled 120608 9:56:17 InnoDB: Mutexes and rw_locks use InnoDB's own implementation 120608 9:56:17 InnoDB: Compressed tables use zlib 1.2.3 120608 9:56:17 InnoDB: Using linux native AIO 120608 9:56:17 InnoDB: Initializing buffer pool, size = 128.0M 120608 9:56:17 InnoDB: Completed initialization of buffer pool InnoDB: Unable to lock ./ibdata1, error: 11 InnoDB: Check that you do not already have another mysqld process InnoDB: using the same InnoDB data or log files. 120608 9:56:17 InnoDB: Retrying to lock the first data file InnoDB: Unable to lock ./ibdata1, error: 11 InnoDB: Check that you do not already have another mysqld process InnoDB: using the same InnoDB data or log files. InnoDB: Unable to lock ./ibdata1, error: 11 InnoDB: Check that you do not already have another mysqld process InnoDB: using the same InnoDB data or log files. InnoDB: Unable to lock ./ibdata1, error: 11 ...
好像是原來的 mysqld 並沒有停下來。
強制終止 mysqld
[root@www ~]$ ps -ef|grep mysql root 4769 1 0 Jun06 "jb51code">[root@www ~]$ service mysql start Starting MySQL. SUCCESS! [root@www ~]$ [root@www ~]$ [root@www ~]$ [root@www ~]$ [root@www ~]$ service mysql start Starting MySQL SUCCESS! [root@www ~]$前面 www.err 文件中顯示的 error: 11 到底是什麽,看下:
[root@www ~]$ perror 11 OS error code 11: Resource temporarily unavailable [root@www ~]$ [root@www ~]$如有疑問請留言或者到本站社區交流討論,感謝閱讀,希望能幫助到大家,謝謝大家對本站的支持!
Tags: InnoDB mysql 120608 MySQL 啟動 service文章來源: