Install MariaDB in Ubuntu 12.04/12.10/13.10

MariaDB is a database server that offers drop-in replacement functionality for MySQL. MariaDB is built by some of the original authors of MySQL, with assistance from the broader community of Free and open source software developers. In addition to the core functionality of MySQL, MariaDB offers a rich set of feature enhancements including alternate storage engines, server optimizations, and patches.
In this tutorial explain how to install and secure MariaDB in Ubuntu 12.04/12.10/13.10 server.

Install MariaDB

First need to enable MariaDB repository.
Here are the commands to run to add MariaDB to your system:

# sudo apt-get install python-software-properties
# sudo apt-key adv --recv-keys --keyserver hkp:// 0xcbcb082a1bb943db

Add MariaDB repository to Ubuntu 12.04

# sudo add-apt-repository 'deb precise main'

Add MariaDB repository to Ubuntu 12.10

# sudo add-apt-repository 'deb quantal main'

Add MariaDB repository to Ubuntu 13.10

# sudo add-apt-repository 'deb saucy main'

Once the key is imported and the repository added you can install MariaDB with:

# sudo apt-get update
# sudo apt-get install mariadb-server

While installing MariaDB using above command installer will prompt for MariaDB root account password twice like below snapshot.

Set MariaDB root password
Set MariaDB root password

Starting MariaDB

After complite installation process, start MariaDB width following command:

# sudo service mysql start

Try to connect to MariaDB:

# mysql -u root -p
Enter password:
Welcome to the MariaDB monitor. Commands end with ; or g.
Your MariaDB connection id is 35
Server version: 5.5.36-MariaDB-1~saucy-log binary distribution
Copyright (c) 2000, 2014, Oracle, Monty Program Ab and others.
Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
MariaDB [(none)]>

That’s it. For questions please use comments.
See also:
How to install MariaDB 5.5.33a Database on RHEL/CentOS/Fedora linux
Install MariaDB 10.0 on CentOS linux using YUM command
How to install MariaDB on Ubuntu 18.10

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *


This site uses Akismet to reduce spam. Learn how your comment data is processed.

Back to top button