PDA

View Full Version : How i fixed: mysql has failed, please contact the sysadmin



Fli
05-01-2014, 10:09 PM
I restarted mysqld from WHM/cPanel and result was:


mysql has failed, please contact the sysadmin (result was "mysql is not running")

In my case this was result of my recent editation in /etc/my.cnf file. I just opened the file and deleted lines i added. Saved and did:

service mysql start ... and mysql started, OK.


Another advices:


service mysql stop

show mysql processes

ps aux | grep mysql

then:

kill processid

or kill all mysql:

pkill -f mysql

or check /var/run for mysql .pid and remove it

ls -l /var/run | grep mys

rm filename

try start mysql again:

service mysql start

error logs:

tail -n30 /var/log/mysql*

Submit ticket to cPanel (https://tickets.cpanel.net/review/login.cgi) and ask at cPanel forums (http://forums.cpanel.net) (in case you are using WHM/cpanel)