Install LAMP Stack (Apache, MariaDB, php, phpMyAdmin) on Ubuntu 14.04, 14.10, 15.04, 15.10 & 16.04

3) MariaDB installation

MariaDB is a drop-in replacement for MySQL. MariaDB is opensource relational database management system (RDBMS) which is supporting database access.

By default all the distribution included MariaDB 5.x to own repository, if you want to install, simply you can run apt-get install mariadb-server.

If you want to install MariaDB 10.x, you need to add MariaDB 10.x repo additionally on your system because it’s not included in distribution repository.

[Add MariaDB 10.1 Repo]
$ sudo apt-get install software-properties-common
$ sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xcbcb082a1bb943db
$ sudo add-apt-repository 'deb [arch=amd64,i386] http://mirrors.opencas.cn/mariadb/repo/10.1/ubuntu '$(lsb_release -cs)' main'
$ sudo apt-get update
$ sudo apt-get -y install mariadb-server

Start, enable & check status of MariaDB service on your System

[Start, enable & check status of MariaDB service on systemd System]
$ sudo systemctl start mariadb.service
$ sudo systemctl enable mariadb.service
$ sudo systemctl status mariadb.service

[Start, enable & check status of MariaDB service on Sysvinit System]
$ sudo service mysqld start
$ sudo chkconfig mysqld on

While installing MariaDB server, it will ask you to set root password for MariaDB.
install-lamp-on-ubuntu-16-04-mariadb-1
Confirm the root password for MariaDB.
install-lamp-on-ubuntu-16-04-mariadb-2

Magesh Maruthamuthu

Love to play with all Linux distribution

You may also like...