Debian is the most stable Linux distributions out there. This is because the packages that are part of the official repositories are frozen and tested many times by many people. However, this brings a consequence: that we will not be able to have the most recent versions of the programs. An example of this is MariaDB which is a vital program for many people. So, today I will show you how to install MariaDB 10.5 on Debian 10.
MariaDB is a well-known archi Database Relationships Management System that is a MySQL fork. This is due to the purchase of Sun Mycrosystem by Oracle. It is perfectly compatible with MySQL and is available in most Linux distributions.
In Debian 10 the version of MariaDB that is available in the official repositories is 10.3 but recently has seen the release of version 10.5 with some interesting new features.
So, if you want to take advantage of having a recent version of this database manager, then welcome.
Install MariaDB 10.5 on Debian 10
For recent versions of MariaDB on Debian 10, we can use the repository provided by the developers.
These repositories have many mirrors around the world, I will use one that is in New York that should work well anywhere.
So, open a terminal and install the necessary packages to add the repository.
sudo apt-get install software-properties-common dirmngr
After you have done this, add the GPG key to it
sudo apt-key adv --fetch-keys 'https://mariadb.org/mariadb_release_signing_key.asc' Executing: /tmp/apt-key-gpghome.WyUWC7PYTX/gpg.1.sh --fetch-keys https://mariadb.org/mariadb_release_signing_key.asc gpg: requesting key from 'https://mariadb.org/mariadb_release_signing_key.asc' gpg: key F1656F24C74CD1D8: public key "MariaDB Signing Key email@example.com" imported gpg: Total number processed: 1 gpg: imported: 1
Now yes, add the repository in question.
sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el] http://nyc2.mirrors.digitalocean.com/mariadb/repo/10.5/debian buster main'
And refreshes APT
sudo apt update
And finally, it carries out the installation
sudo apt install mariadb-server Reading package lists… Done Building dependency tree Reading state information… Done The following additional packages will be installed: galera-4 gawk libdbi-perl libgdbm-compat4 libmariadb3 libmpfr6 libperl5.28 libsigsegv2 mariadb-client-10.5 mariadb-client-core-10.5 mariadb-common mariadb-server-10.5 mariadb-server-core-10.5 mysql-common perl psmisc socat Suggested packages: gawk-doc libclone-perl libmldbm-perl libnet-daemon-perl libsql-statement-perl mailx mariadb-test netcat-openbsd perl-doc libterm-readline-gnu-perl | libterm-readline-perl-perl make libb-debug-perl liblocale-codes-perl Recommended packages: libdbd-mariadb-perl | libdbd-mysql-perl libterm-readkey-perl libhtml-template-perl The following NEW packages will be installed: galera-4 gawk libdbi-perl libgdbm-compat4 libmariadb3 libmpfr6 libperl5.28 libsigsegv2 mariadb-client-10.5 mariadb-client-core-10.5 mariadb-common mariadb-server mariadb-server-10.5 mariadb-server-core-10.5 mysql-common perl psmisc socat 0 upgraded, 18 newly installed, 0 to remove and 12 not upgraded. Need to get 32.9 MB of archives. After this operation, 248 MB of additional disk space will be used. Do you want to continue? [Y/n]
After the installation is complete, check the installed version:
mysql --version mysql Ver 15.1 Distrib 10.5.8-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
And remember that you have to configure MariaDB before putting it into production.
Remove anonymous users? [Y/n]
Disallow root login remotely? [Y/n]
Remove test database and access to it? [Y/n]
Reload privilege tables now? [Y/n]
And now it will be ready.
MariaDB 10.5 is a good improvement over previous versions. But it is not always available in the official repositories of other Linux distributions. Today you have learned how to install it in Debian 10.