mysql使用出现错误:mysqld dead but subsys locked

现象:

  登陆时候出现如下信息

  

[root@localhost home]# mysql -uroot -p123456
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

[root@localhost home]#

 

查看mysql状态:

[root@localhost home]# service mysqld status
mysqld dead but subsys locked
[root@localhost home]#

 

解决方法:  修改mysqld的权限

      chown -R mysql.mysql /var/run/mysqld

posted @ 2018-01-06 15:22  Bestone  阅读(2407)  评论(0编辑  收藏  举报