Remove MySQL completely

Using package management is great. Adding MySQL to your box is a doddle!
Unfortunately, getting rid of MySQL once you’ve installed it leaves
stuff behind.

You will find that your databases and user configurations (including
usernames and passwords) are left on your box even after you have used
your package manager to remove MySQL.

So, use the following to get rid of it totally:

 apt-get purge mysql-server mysql-common mysql-client-<version> apt-get autoremove rm -rf /var/lib/mysql rm -rf /etc/mysql* 

Khash Sajadi

Khash is the founder and CEO of Cloud 66, a full stack container management as a service. Follow him on @khash

London, UK and San Francisco, US
Subscribe and get updates

Thank you! We keep in touch.

Have feedback? Please get in touch @cloud66 on Twitter.

Try Cloud 66 for Free, No credit card required