./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).
这里有高手可以告诉我原因么?
5 个解决方案
#1
你在看linux就该这样学哇?
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
日志没报错了的话,后面还有问题检查/var/lib/mysql/linuxprobe.com.pid这个文件目录存在不。
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
日志没报错了的话,后面还有问题检查/var/lib/mysql/linuxprobe.com.pid这个文件目录存在不。
#2
/var/lib/mysql/linuxprobe.com.pid这个文件夹我也找不到 貌似不存在
#3
我通过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文件了呀,可以进一步帮我分析问题出在哪里么?
#4
/etc/my.cnf中这是配置的文件路径。
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
主要看下有没有这个文件夹,没有的话给他创建,并授权,要不然没有权限创建,mysql就会启动不了、
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
主要看下有没有这个文件夹,没有的话给他创建,并授权,要不然没有权限创建,mysql就会启动不了、
#5
安装mysql的时候,先检查系统里面的自带的mariadb删除干净了没,你启动的是mariadb 。删掉他,再重新安装
#1
你在看linux就该这样学哇?
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
日志没报错了的话,后面还有问题检查/var/lib/mysql/linuxprobe.com.pid这个文件目录存在不。
'/var/log/mariadb/mariadb.log', however file don't exists. Create writable for user
这里报的是log文件不存在,mysql用户又没有权限创建。
创建/var/log/mariadb/mariadb.log文件,授权给mysql用户。
日志没报错了的话,后面还有问题检查/var/lib/mysql/linuxprobe.com.pid这个文件目录存在不。
#2
/var/lib/mysql/linuxprobe.com.pid这个文件夹我也找不到 貌似不存在
#3
我通过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文件了呀,可以进一步帮我分析问题出在哪里么?
#4
/etc/my.cnf中这是配置的文件路径。
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
主要看下有没有这个文件夹,没有的话给他创建,并授权,要不然没有权限创建,mysql就会启动不了、
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
主要看下有没有这个文件夹,没有的话给他创建,并授权,要不然没有权限创建,mysql就会启动不了、
#5
安装mysql的时候,先检查系统里面的自带的mariadb删除干净了没,你启动的是mariadb 。删掉他,再重新安装