MySQL 8.0.13 systemctl start throws error 13
Sorry for the long post, but I wanted to get all the necessary information.
When I do a sudo systemctl start mysqld.service it generates and error 13 in the error log.
/var/log/mysqld.log
mysqld: File './binlog.index' not found (OS errno 13 - Permission denied)
2019-05-06T22:50:26.608886Z 0 [Warning] [MY-010091] [Server] Can't create test file /data/mysql/hsvsmimedev.lower-test
2019-05-06T22:50:26.608972Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.16) starting as process 17347
2019-05-06T22:50:26.612524Z 0 [Warning] [MY-010091] [Server] Can't create test file /data/mysql/hsvsmimedev.lower-test
2019-05-06T22:50:26.612543Z 0 [Warning] [MY-010159] [Server] Setting lower_case_table_names=2 because file system for /data/mysql/ is case insensitive
2019-05-06T22:50:26.613641Z 0 [ERROR] [MY-010119] [Server] Aborting
2019-05-06T22:50:26.613908Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.16) MySQL Community Server - GPL.
Here's the /etc/my.cnf - bare bones:
[mysqld]
user=mysql
datadir=/data/mysql
#datadir=/var/lib/mysql
socket=/data/mysql/mysql.sock
#socket=/var/lib/mysql/mysql.sock
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
The /data/MySQL has correct permissions:
drwxr-x---. 6 mysql mysql 4096 May 6 10:33 MySQL
It did start/stop at first with the default /var/lib/MySQL datadir, I modified datadir and it began failing. Restoring the datadir to /var/lib/MySQL didn't work. Since 8.0 seems to auto-init I deleted the datadir contents on each start attempt.
Looking at the log and running journalctl -xe it looks like the service starts as MySQL, creates the databases, then tries to run as mysqld (hence permission denied).
Server's running Red Hat Enterprise 7.
Thanks
Subject
Written By
Posted
MySQL 8.0.13 systemctl start throws error 13
May 06, 2019 05:02PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.