Install MariaDB On CentOS 6.5/6.4

MariaDB is a community-developed fork of the MySQL relational database management system, the impetus being the community maintenance of its free status under the GNU GPL. Being a fork of a leading open source software system, it is notable for being led by its original developers and triggered by concerns over direction by an acquiring commercial company Oracle.

Add repository on Centos 6 32-bit

# vi /etc/yum.repos.d/MariaDB.repo

and paste following line:

  
 [mariadb]
 name = MariaDB
 baseurl = http://yum.mariadb.org/5.5/centos6-x86
 gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
 gpgcheck=1

Add repository on Centos 6 64-bit

[mariadb]    
name = MariaDB
baseurl = http://yum.mariadb.org/5.5/centos6-amd64    
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB   
gpgcheck=1

Start Install

# yum install MariaDB-server MariaDB-client -y

After complete installation process, start MariaDB :

 # service mysql start

Set MariaDB to start on boot:

# chkconfig mysql on

 Secure MariaDB after installation to :

– Set (Change) root password
– Remove anonymous users
– Disallow root login remotely
– Remove test database and access to it
– Reload privilege tables

[root@Unixmen-centos65 Downloads]# mysql_secure_installation

 Check the new root password and databases:

# mysql  -u root -p
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 13
Server version: 5.5.34-MariaDB MariaDB Server
Copyright (c) 2000, 2013, Oracle, Monty Program Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show  databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
+--------------------+
3 rows in set (0.00 sec)

MariaDB [(none)]>