MySQL won't start help! Print

  • 0

The issue is that the .sock file for mysql is present even when the service wasn't started, so when it tried to restart, it saw the .sock and got confused.

To fix this issue please do the following:
cd /var/lib/mysql/ does mysql.sock exist?

If it is, then run rm -rf ./var/lib/mysql/mysql.sock to delete the socket file, and then try to start the mysqld service.


If the service is still running:

service mysqld status
mysqld (pid 213060 3994) is running...

Run kill -9 pid (eg: kill -9 213060) for both pid's. Then do service mysqld stop.

After check if MySQL is working at all: service mysqld status it should say: mysqld is stopped.

Then finally run service mysqld start. It should say Starting mysqld: [ OK ]

You can run: mysqlcheck -u root -p --auto-repair --all-databases.


Was this answer helpful?

« Back