CentOS7中安装mysql遇见的问题及解决方案
问题一:
error: log-error set to '/usr/local/mysql/softtware/logs/mysqld.log', however file don't exists. Create writable for user 'mysql'.
解决方案:
- 首先检查my.cnf配置的路径是是否正确
- 如果正确则进行如下操作
cd /usr/local/software/mysql
echo "" > /usr/local/software/mysql/logs/mysqld.log
chown -R mysql:mysql /usr/local/software/mysql/logs/mysqld.log
service mysqld start
启动成功!
问题二:
Can 't connect to local MySQL server through socket '/tmp/mysql.sock '(2) "
解决方案:
#建立软连接
ln -s /var/run/mysqld/mysqld.sock /tmp/mysql.sock
本文地址:https://blog.csdn.net/TQ20160412/article/details/111914499