How to uninstall MariaDB

This article will walk you through all the steps to uninstall MariaDB in Windows, Linux, Ubuntu, etc. You can install MariaDB on your computer if you have not yet done so.

How to uninstall MariaDB

Let us discuss all the cases individually.

Case-1 In Windows

There are several methods to uninstall MariaDB from Windows. Some of them are mentioned below.

Method 1

When any new piece of program is installed on your computer, that program is added to the list of Programs and Features. You can uninstall the program from that list.

To uninstall MariaDB, follow the below steps.

1. Press the Windows and X keys together to open a menu and click on Apps and Features at the top of the menu.

how to uninstall mariadb windows

2. Then, the Setting Window will open. In that window, you need to click on Programs and Features at the top-right corner.

how to uninstall mariadb windows 10

3. You will see the list of programs installed on your computer. Select MariaDB and then click on the Uninstall Button.

uninstall mariadb windows 10

Method 2

In this method, you only need to go to MariaDB’s installation file and find uninstall.exe or unins000.exe. Then, double-click on it and follow the wizard to uninstall MariaDB.

Method 3

This method does not obliterate MariaDB, so you do not need to uninstall it manually. However, it’s recommended that you uninstall MariaDB with a trusted third-party uninstaller that can identify and remove all MariaDB files.

NoteIf nothing works, we can uninstall MariaDB via System restore by choosing a Restore point. However, you need to back up the data created or installed on your computer after the installation of MariaDB.

Read How to Create Database in MariaDB

Case-2 In Linux

To uninstall mariadb in linux, follow the below steps.

1. For uninstallation of MariaDB in Linux CentOS, you need to run the below command

sudo yum remove MariaDB-server MariaDB-client

When you don’t have a MariaDB client, you run the above command without MariaDB-client.

2. The uninstallation process does not erase the data directory /var/lib/mysql. For future use we can leave it for further use. Otherwise, we can remove it by using the below command.

sudo rm -r /var/lib/mysql

Case-3 In Ubuntu

To uninstall MariaDB in Ubuntu, you need to follow these steps.

1. Before the uninstallation process, you need to run the statement to see MariaDB’s status and version.

systemctl status mariadb

2. In this step, you need to run the purge command to erase the package of MariaDB.

apt purge "mariadb*" -y

3. Now, run the autoremove command to delete the configuration files completely.

apt autoremove -y

4. To verify that the uninstallation is completed, you need to check the status of the MariaDB service.

systemctl status mariadb

The output of this command will ensure you the uninstallation of the MariaDB service.

You may also like following the articles below.

Top 200 SQL Server Interview Questions and Answers

Free PDF On Top 200 SQL Server Interview Questions And Answers

Download A 40 pages PDF And Learn Now.