Base OS: Centos 7 Atomic Host
I installed Mariadb 10.2 & changed the data directory to a folder under /home directory. I made the respective changes to /etc/my.cnf to point to the data directory & mysql socket. I also did the concerned changes in SE linux context. Now, when I start the mariadb service by systemctl start mariadb it fails. The output to the system status mariadb.service is
Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.
# systemctl status mariadb.service
● mariadb.service - MariaDB database server
Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; vendor preset: disabled)
Drop-In: /etc/systemd/system/mariadb.service.d
└─migrated-from-my.cnf-settings.conf
Active: failed (Result: exit-code) since Tue 2017-09-12 13:54:15 CEST; 23s ago
Process: 3099 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=1/FAILURE)
Process: 3066 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`/usr/bin/galera_recovery`; [ $? -eq 0 ] && systemctl set-environment _WSREP_START_POSITION=$VAR || exit 1 (code=exited, status=0/SUCCESS)
Process: 3063 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Main PID: 3099 (code=exited, status=1/FAILURE)
Status: "MariaDB server is down"
/etc/my.cnf is
[client-server]
[mysqld]
datadir=/home/data/db/mysql
socket=/home/data/db/mysql/mysql.sock
[client]
port=3306
socket=/home/data/db/mysql/mysql.sock
Any ideas on how to get MariaDB up & running?