作者:佚名 时间:2024-05-31 12:50:48 阅读:(18)
最近在排查服务器的时候发现mysql数据库很多sql语句等待的时间过长,在重启mysql之后却报错ERROR! Failed to stop running server, so refusing to try to start,接下来云梦编程为大家介绍一下解决方法,有需要的小伙伴可以参考一下:
[root@localhost ~]# service mysql restart Shutting down MySQL.................................................................................... ....................................................................................................... ....................................................................................................... ....................................................................................................... ................................................................................................ ERROR! ERROR! Failed to stop running server, so refusing to try to start.
可以使用ps命令来查找到我们所需要的进程ID,然后kill -9杀掉对应的进程
[root@localhost ~]# ps -ef | grep mysql root 8362 1 0 2021 ? 00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/var --pid-file=/usr/local/mysql/var/location.pid mysql 8928 8362 16 2021 ? 15-13:34:23 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/var --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --log-error=/var/log/mysqld.log --open-files-limit=65535 --pid-file=/usr/local/mysql/var/location.pid --socket=/tmp/mysql.sock --port=3306 root 14623 1307 0 14:51 pts/7 00:00:00 /bin/sh /usr/sbin/service mysql restart root 14630 14623 0 14:51 pts/7 00:00:00 /bin/sh /etc/init.d/mysql restart root 14638 14630 0 14:51 pts/7 00:00:00 /bin/sh /etc/init.d/mysql stop root 16523 15291 0 15:04 pts/8 00:00:00 grep --color=auto mysql
service mysql restart
以上就是云梦编程为大家介绍的关于Mysql重启提示Failed to stop running server, so refusing to try to start.解决方法的全部内容了,了解更多相关文章请关注云梦编程网!