- Plesk Onyx for Linux
- MySQL is unable to start.
- The following error is shown when querying the status of the service:
# service mysqld status
mysqld dead but subsys locked
- Amount of free memory on the server is low.
MySQL failed because of lack of free memory and leave
/var/lock/subsys/mysqld file behind.
it is required to remove
/var/lock/subsys/mysqld file, free up some memory and start MySQL.
Note: Actions described below require administrative skills, in case you have any difficulties with it, reboot the server to fix the issue. Consider increasing the amount of RAM on the server in order to prevent such issues from happening in the future.
- Log into the server via SSH.
# rm -f /var/lock/subsys/mysqld
- Check the amount of free memory with
free -mcommand. In case there is more then 200M free, skip this step. In case amount of free memory is low, kill processes that consumes most of the memory. For example, stop the Apache temporary:
# service httpd stop
- Try to start MySQL:
# service mysqld start
- In case Apache is stopped on step 3, start it back:
# service httpd start