I want to completely remove MySQL from my system, including databases, settings, logs, journals, etc.
How can I do it?
Update/Note: The MySQL was installed using the following terminal commands:
sudo apt update
sudo apt install mysql-server
sudo mysql_secure_installation
OS Name: Ubuntu 20.04.1 LTS
OS Mode: Live USB drive with persistent storage
MySQL version: mysql Ver 8.0.20
As you already know how you installed it and what version you're working with, you can do the following:
Stop the MySQL service:
Purge MySQL, databases, and configurations:
Remove any additional database files:
The folder where the configuration was and any stranglers:
Clean the logs:
Delete the user-generated during installation:
Finally, get rid of the usergroup that was created during installation:
That should get rid of everything. If you installed a third-party PPA in order to install MySQL then you'll need to remove that.
And that should be everything related to MySQL and nothing else.
This is what I did, in ubuntu terminal i located mysql by typing in
For which I got an output
Further mysql was inside lampp as well, i located it by
For which I got an output
Then i typed in
and pressed enter to open as root, after which I typed in and removed mysql in one location
Did a restart. and again opened as root in ubuntu terminal and typed in location of mysql inside lampp
Again did a system restart.Next in terminal i typed in
I got the output mysql cannot be located, for reassurance purpose I typed in
No output, mysql has been uninstalled