MySQL manager or server PID file could not be found!
2013-10-08 09:54
393 查看
放假之前数据库还正常呢,但是回来之后发现服务器重启之后,数据库无法启动了,提示报错
MySQL manager or server PID file could not be found!
从网上查到的方法为:
首先查看一下进程
[root@centos mysql]# ps aux |grep mysq*
root 2643 0.0 0.2 4536 1224 ? S 01:09 0:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/var --pid-file=/usr/local/mysql/var/centos.pid
mysql 2757 0.0 1.2 36976 6608 ? Sl 01:09 0:00 /usr/local/mysql/libexec/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/var --user=mysql --log-error=/usr/local/mysql/var/centos.err
--pid-file=/usr/local/mysql/var/centos.pid --socket=/tmp/mysql.sock --port=3306
root 4788 0.0 0.1 3920 684 pts/2 R+ 11:11 0:00 grep mysq*
如果看到上面的内容,那说明,Mysql的进程卡死了,这时用就要把这些卡死的进程都关闭
[root@centos mysql]# kill 2643
[root@centos mysql]# kill 2757
启动Mysql 就ok了
[root@centos mysql]# service mysqld start
Starting MySQL. [ OK ]
但是我的问题还是没有解决:
最后没有办法只能去查看错误日志:
/usr/local/mysql/var/centos.err
发现报错信息为:
unable to lock /usr/local/mysql/var/ibdata1
去目录下查看ibdata1文件,发现日志文件mysql.bin文件特别多,还都挺大,把过期日志删除掉,重启数据库,发现还是不行,继续查看错误日志,谢天谢地,报错信息换了,变成了3306端口被占用。
netstat -anp|grep 3306 找到占用端口的进程ID
kill -9 端口号 强制关闭进程
service mysql rstart 解决问题。
总结:有的时候错误提示不一定是正确的,查看错误日志为根本。
MySQL manager or server PID file could not be found!
从网上查到的方法为:
首先查看一下进程
[root@centos mysql]# ps aux |grep mysq*
root 2643 0.0 0.2 4536 1224 ? S 01:09 0:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/var --pid-file=/usr/local/mysql/var/centos.pid
mysql 2757 0.0 1.2 36976 6608 ? Sl 01:09 0:00 /usr/local/mysql/libexec/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/var --user=mysql --log-error=/usr/local/mysql/var/centos.err
--pid-file=/usr/local/mysql/var/centos.pid --socket=/tmp/mysql.sock --port=3306
root 4788 0.0 0.1 3920 684 pts/2 R+ 11:11 0:00 grep mysq*
如果看到上面的内容,那说明,Mysql的进程卡死了,这时用就要把这些卡死的进程都关闭
[root@centos mysql]# kill 2643
[root@centos mysql]# kill 2757
启动Mysql 就ok了
[root@centos mysql]# service mysqld start
Starting MySQL. [ OK ]
但是我的问题还是没有解决:
最后没有办法只能去查看错误日志:
/usr/local/mysql/var/centos.err
发现报错信息为:
unable to lock /usr/local/mysql/var/ibdata1
去目录下查看ibdata1文件,发现日志文件mysql.bin文件特别多,还都挺大,把过期日志删除掉,重启数据库,发现还是不行,继续查看错误日志,谢天谢地,报错信息换了,变成了3306端口被占用。
netstat -anp|grep 3306 找到占用端口的进程ID
kill -9 端口号 强制关闭进程
service mysql rstart 解决问题。
总结:有的时候错误提示不一定是正确的,查看错误日志为根本。
相关文章推荐
- MySQL manager or server PID file could not be found!
- ERROR! MySQL manager or server PID file could not be found!
- MySQL manager or server PID file could not be found![FAILED]
- linux安装mysql 报 ERROR! MySQL manager or server PID file could not be found!
- mysql启动报错 MySQL manager or server PID file could not be found! [FAILED]
- Mysql服务启动错误之(MySQL manager or server PID file could not be found)
- 解决 MySQL manager or server PID file could not be found! 的方法
- MySQLmanager or server PID file could not be found! 分类: database ubuntu 2014-01-22 16:29 313人阅读 评论(0) 收藏
- MySQL manager or server PID file could not be found!
- MySQLmanager or server PID file could not be found!
- 解决 MySQL manager or server PID file could not be found! 的方法
- MySQL manager or server PID file could not be found!
- MySQL manager or server PID file could not be found! 的方法
- MySQL manager or server PID file could not be foun
- MysqL错误之_ERROR! MySQL server PID file could not be found!
- MySQL server PID file could not be found!
- MySQL server PID file could not be found!
- MySQL启动错误ERROR! MySQL server PID file could not be found的解决办法
- MySQL server PID file could not be found!
- 重启mysql提示MySQL server PID file could not be found!