mysql / mariadb will not start


New Member

Messages: 2

I installed mariadb in a jail and was working but now it will not start. I don't care about the data, i'm learning.
what I did:
spin up new jail
pkg install mariadb104-server : no errors
service mysql-server start : installs in /var/db/mysql
service mysql-server status
mysql is not running
service mysql-server start
service mysql-server status
mysql is not running
mysql -u root -p
error 2002 (hy000): can't connect to local mysql server through socket '/tmp/mysql.sock'
obviously, it's not running
i've done
pkg remove mariadb104-server : no errors
pkg autoremove : no errors
rm -r /var/db/mysql
reinstalled mariadb
no my.cnf file to edit
"/var/.../database test.err" shows "...mysqld: too many arguments (first extra is '')."
but there is no my.cnf file to fix


Son of Beastie

Reaction score: 162
Messages: 3,377

I just tried this to see what I got...
pkg installsy -y mariadb104-server
sysrc mysql_enable=YES
service mysql-server status
This resulted in:-
mysql is running as pid 1053.
That's all I did, and think that is all that is required.

I suspect you have something like a mysql.sock hanging around in /tmp preventing mysql from starting.

Check /var/db/mysql/Mysql.err. It may give you some clues.