Ubuntu – Is MySQL still running after uninstall it

MySQL

I had mysql server running. I stopped it, and removed it (apt-get remove mysql-server mysql-client)

I then manually removed the directories:

/var/lib/mysql
/var/run/mysqld

I rebooted. But when I type mysql, I get the following message:

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

I get the same error message when I type service mysql stop

This means mysql server is still running. How do I get rid of it completely and stop the process.

Best Answer

The error does not mean that you still have MYSQL server running. In fact, if the client can not connect to it, probably you don't have it running.

You still have the client available for execution: mysql

You can find out the package where mysql is, with:

dpkg -S `which mysql`

Then remove it, if you really want to do that.

Related Question