MariaDB is free, open-source RDBMS and drop-in-replacement (compatible) for MySQL database server and have many similarity both in syntax, commands and its coding style. In the earlier version of MariaDB database server, excatly MariaDB 5.1 it was based on MySQL 5.1 database server. Some of the founder and original MariaDB developer force to fork MySQL to MariaDB due to concern at that time. It maintenance and actively developed under MariaDB Foundation.
It caused where MySQL AB as a largest-ever open source RDBM on the world acquired by big company at 2010, Oracle Corporation. Since that time MySQL became a part of Oracle following Sun Microsystem acquisition in 2010. So, all aspects and work teams on MySQL AB taken over by Oracle teams, including engineering team, marketing, sales, and support or help desk.
Many MySQL users and open-source software enthusiats at that time very sad about this news. Considering that spirit of free and open-source software not showing again on MySQL. Unlike MariaDB with their open source spirit, if you want to have great and good database server environment, including in term of the high-performance, reliability, and scalability under MySQL you must buy the Enterprise Edition. You must pay for it with a lot of money, check the following screenshot.
Well, MariaDB bridges that and give their users free and open-source RDBM (Relational Database Management System) under the GPL license version 2+. So, you can use, modify, and distribute MariaDB (including their client libraries with any apps) freely without at any costs. The open-source spirit you can found here, where you can have also build high-performance, reliable and scalable database server with MariaDB Galera Clusters.
Currently MariaDB have three newest database server versions, including MariaDB 10.6 (LTS), MariaDB 10.7 (STS), and MariaDB 10.8 (DEV). Well, MariaDB 10.6 is the current long-term support stable version which was released in July 2021 and will be supported until July 2026. While stable version of MariaDB 10.7 have short-term support only and will still be supported from February 2022 until February 2023. Unlike above versions, MariaDB 10.8.0 became current development series of MariaDB database server. So this version is focused for development only, and offers some evolution and several entirely new features compared to the previous version of MariaDB database server.
If you want to install, configure and deploy MariaDB database server we strongly recomend to use MariaDB 10.6, instead of MariaDB 10.7 or MariaDB 10.8. Kindly read the following guide to install and configure MariaDB 10.6 database server on Ubuntu 20.04 LTS (Focal Fossa). It can be applied on almost all server, workstations, or local desktop environments, either it run under virtual machine, vps, cloud computing, bare metal, phisycal server or dedicated server.
PREREQUISITES: * Virtual Machine, Workstation, Localhost, VPS, Cloud or Physical Servers * OS Distro with Ubuntu 20.04 LTS (Focal Fossa) * Superuser Privileges (Root Access) * Should ber familiar with CLI-Based Interface or Command-Line Only * Gnome Terminal for Linux Desktop * PuTTy SSH Client for Windows or Mac * Powershell for Windows 10/11
1.) Simply Open the MariaDB Setting Up Repository or MariaDB Download Page
As one of the world’s most popular open source RDBMS, MariaDB is available in the standard repositories on all major Linux distributions, incuding RHEL/CentOS/Alma/Rocky Linux and all Debian/Ubuntu families. To deploy MariaDB on Debian/Ubuntu based system you can use APT package repository. After that choose your distribution to 20.04 “focal”, choose a MariaDB Server version to “10.6” and then choose Mirror Donwload to “Yamagata University, Yonezawa” or closed mirror download with your current server locations.
2.) Connect To Your Server Over SSH Terminal
Simply run the following command if you are currently running Linux with Gnome Desktop or Windows Machine with Their Powershell.
~# ssh root@server_IPv4_address -p22 Password:
3.) Finally, Let’s Run the Following Commands to install MariaDB 10.6 on your Ubuntu system with Official MariaDB APT Repository.
~# sudo apt-get install software-properties-common dirmngr apt-transport-https ~# sudo apt-key adv --fetch-keys 'https://mariadb.org/mariadb_release_signing_key.asc' ~# sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el,s390x] https://ftp.yz.yamagata-u.ac.jp/pub/dbms/mariadb/repo/10.6/ubuntu focal main'
4.) Alternatively, You Can Create a File Called MariaDB.list Under /etc/apt/sources.list.d Directory.
Apart from the above method, you can also create custom “MariaDB.listt” file or something similar file under “/etc/apt/sources.list.d” directory. Then paste the following snippet code in the MariaDB.listt file or simply add these deb packages “Debian packages” (.deb files for Debian/Ubuntu-based Linux Distributions) at the bottom line of the file of “/etc/apt/sources.list”.
# MariaDB 10.6 repository list - created UTC # https://mariadb.org/download/ deb [arch=amd64,arm64,ppc64el,s390x] https://ftp.yz.yamagata-u.ac.jp/pub/dbms/mariadb/repo/10.6/ubuntu focal main deb-src https://ftp.yz.yamagata-u.ac.jp/pub/dbms/mariadb/repo/10.6/ubuntu focal main
5.) Run System Update, Then Install MariaDB 10.6
After you’ve imported MariaDB Signing Key and the official MariaDB repository have added to your Ubuntu machine, simply run with the following commands to install MariaDB 10.6 Database Server.
~# sudo apt update ~# sudo apt install mariadb-server
6.) Enable MariaDB From Boot and Let’s Start it
During installation proccess MariaDB would be set to automatically enabled and started since your machine booted. However, if you found that your MariaDB Service not set to automatically enabled and started from booted, you can simply set it with the following commands later.
~# systemctl enable mysql.service Created symlink /etc/systemd/system/multi-user.target.wants/mariadb.service → /lib/systemd/system/mariadb.service. mariadb-extra.socket is a disabled or a static unit, not starting it. mariadb-extra.socket is a disabled or a static unit, not starting it. ~# systemctl start mysql.service
7.) Securing and Hardening MariaDB Installation
This is important step and best practice on Cyber Security industry that should be applied on all MariaDB Installation. So, if you want your MariaDB Server have more secure and harden environment, kindly to applied this method.
~# mysql_secure_installation
~# mysql -V mysql Ver 15.1 Distrib 10.6.7-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
That’s all, you have successfully install and configure MariaDB 10.6 database server under Ubuntu 20.04 LTS (Focal Fossa) on your machine.