使用 mysqld_safe 启动 mysql server 5.7.17 时,出现以下错误.
While starting mysql server 5.7.17 using mysqld_safe, following error occcours.
2017-02-10T17:05:44.870970Z mysqld_safe Logging to '/var/log/mysql/error.log'.
2017-02-10T17:05:44.872874Z mysqld_safe Logging to '/var/log/mysql/error.log'.
2017-02-10T17:05:44.874547Z mysqld_safe Directory '/var/run/mysqld' for UNIX socket file don't exists.
如何解决?
这个目录不是在安装时创建的,这看起来很奇怪 - 您是否手动更改了 my.cfg 中套接字文件的路径?
It seems odd that this directory was not created at install - have you manually changed the path of the socket file in the my.cfg?
您是否尝试过简单地自己创建此目录并重新启动服务?
Have you tried simply creating this directory yourself, and restarting the service?
mkdir -p /var/run/mysqld
chown mysql:mysql /var/run/mysqld
这篇关于UNIX 套接字文件的 mysqld_safe 目录“/var/run/mysqld"不存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!