16 C
Texas
angeloma
Senior Writer and partner

How to install the latest version of MariaDB on Debian 9?

Debian is a great operating system and may be the most stable within Linux, but it has the disadvantage of not having updated packages. Because of this we gain a lot of stability but lose some novelty. In this article, you will learn how to install the latest version of MariaDB on Debian 9.

MariaDB: The son surpasses the father

After Oracle buys Sun microsystem, there was a huge concern about MySQL’s future. That’s why MariaDB emerges as a 100% compatible fork maintained by the community and the initial creators of MySQL.

The consequences have been positive, as MariaDB being 100% compatible with MySQL ensures that the Community spirit of MySQL is maintained. In addition, large Linux distributions such as Debian, Ubuntu Server or CentOS include it by default in their official repositories, which makes it available easily and simply.

MariaDB website
MariaDB website

Debian is stable but it has a cost

- Advertisement -

As I mentioned earlier, Debian is very stable but its packages are not the latest versions. The great advantage of this is that it makes Debian a very stable distribution but the user misses out on some of the new features corresponding to the packages.

For example, Debian 9 includes MariaDB 10.1 but the last version is 10.3.10.

1.- Debain 9 comes with MariaDB 10.1
1.- Debian 9 comes with MariaDB 10.1

Before we continue let me warn you that, if you have a server in production and you don’t really need the update, you better not do it. While it’s true that the steps I’m going to take are safe, something can always happen. So, be sure.

Install the latest version of MariaDB

MariaDB 10.3.10 is a minor version of the 10.3 series. Some of its main novelties are: bug fixes on InnoDB, corruption of InnoDB temporary tables is corrected and improvements in program performance. As well as to polish the sentences and to add better syntax to the same ones.

There is no easier way to install the latest stable version of MariaDB than by using the MariaDB repository. In addition to ease, it is quite safe to do it this way and thus you are always guaranteed to be prone to an update of the program.

First, upgrade the system.

:~$ su
:~# apt update && apt upgrade

2.- Upgrading the system
2.- Upgrading the system

Doing this ensures that you have the latest security patches installed and have a more stable and reliable system.

Then, install some required packages

:~# install software-properties-common dirmngr

3.- Installing some required packages
3.- Installing some required packages

Next, you have to add the GPG key for the MariaDB repository.

:~# apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xF1656F24C74CD1D8

Now, add the repository.

4.- Adding the MariaDB repository
4.- Adding the MariaDB repository

Refresh the APT cache.

5.- Running apt update command
5.- Running apt update command

Then, install MariaDB packages.

:~# apt install mariadb-server

6.- Install the lastest version of MariaDB
6.- Install the latest version of MariaDB

During installation, you will be asked if you want to define a root password. I chose yes, but you can do it later.

7.- Setting a root password for MariaDB
7.- Setting a root password for MariaDB

Once the installation is finished, you can access the MariaDB console. There you can run the commands and verify the installed version.

:~# mysql -u root -p

8.- Accessing to MariaDB console
8.- Accessing to MariaDB console

As you can see, the version installed is 10.3.10. In short, it is the last version available of MariaDB.

Conclusion

As you can see, the installation of the latest stable version of MariaDB is really simple and does not require many complications. However, it is important, to have at your disposal the new features

- Advertisement -
Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"

2 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here



Latest article