./mysql.server start
失败提示:
[root@linuxprobe support-files]# ./mysql.server start
Starting MySQL.2017-10-26T08:20:34.772472Z mysqld_safe error: log-error set to
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
'mysql'.
ERROR! The server quit without updating PID file
(/var/lib/mysql/linuxprobe.com.pid).
是怎么回事呀????
6 个解决方案
#1
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
#2
创建/var/log/mariadb/mariadb.log文件,在那个var文件呢?我这里mysql安装在usr/local/mysql下的 找不到你说的这个路径????
#3
要在/var/log这个文件夹下创建这个mariadb/mariadb.log文件么?还有授权给mysql用户,我还不会????
#4
我通过vim etc/my.cnf中打开:
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
楼上的高手你帮我看看我这里是不是有/var/log/mariadb/mariadb.log文件了呀,可以进一步帮我分析问题出在哪里么?
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
楼上的高手你帮我看看我这里是不是有/var/log/mariadb/mariadb.log文件了呀,可以进一步帮我分析问题出在哪里么?
#5
直接执行
touch /var/log/mariadb/mariadb.log
chown -R mysql:mysql /var/log/mariadb/
mkdir -p /var/run/mariadb/
chown -R mysql:mysql /var/run/mariadb/
重启数据库即可。
touch /var/log/mariadb/mariadb.log
chown -R mysql:mysql /var/log/mariadb/
mkdir -p /var/run/mariadb/
chown -R mysql:mysql /var/run/mariadb/
重启数据库即可。
#6
看看你的mariadb删了没
# rpm -qa|grep -i mariadb-libs
# rpm -e mariadb-libs-5.5.44-2.el7.centos.x86_64 --nodeps
# rpm -qa|grep -i mariadb-libs
# rpm -e mariadb-libs-5.5.44-2.el7.centos.x86_64 --nodeps
#1
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
#2
创建/var/log/mariadb/mariadb.log文件,在那个var文件呢?我这里mysql安装在usr/local/mysql下的 找不到你说的这个路径????
#3
要在/var/log这个文件夹下创建这个mariadb/mariadb.log文件么?还有授权给mysql用户,我还不会????
#4
我通过vim etc/my.cnf中打开:
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
楼上的高手你帮我看看我这里是不是有/var/log/mariadb/mariadb.log文件了呀,可以进一步帮我分析问题出在哪里么?
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
楼上的高手你帮我看看我这里是不是有/var/log/mariadb/mariadb.log文件了呀,可以进一步帮我分析问题出在哪里么?
#5
直接执行
touch /var/log/mariadb/mariadb.log
chown -R mysql:mysql /var/log/mariadb/
mkdir -p /var/run/mariadb/
chown -R mysql:mysql /var/run/mariadb/
重启数据库即可。
touch /var/log/mariadb/mariadb.log
chown -R mysql:mysql /var/log/mariadb/
mkdir -p /var/run/mariadb/
chown -R mysql:mysql /var/run/mariadb/
重启数据库即可。
#6
看看你的mariadb删了没
# rpm -qa|grep -i mariadb-libs
# rpm -e mariadb-libs-5.5.44-2.el7.centos.x86_64 --nodeps
# rpm -qa|grep -i mariadb-libs
# rpm -e mariadb-libs-5.5.44-2.el7.centos.x86_64 --nodeps