---
title: "How to Install MariaDB on Ubuntu 16"
description: "If you plan on adding a relational database integration to your site, you will need to install a database management program. The open-source MariaDB installation is a popular alternative to MySQL...."
url: https://www.inmotionhosting.com/support/product-guides/cloud-server/install-mariadb-ubuntu-16/
date: 2018-07-05
modified: 2021-08-12
author: "Christopher Maiorana"
categories: ["Cloud Server Hosting"]
type: post
lang: en
---

# How to Install MariaDB on Ubuntu 16

![Install MariaDB on Ubuntu](https://www.inmotionhosting.com/support/wp-content/uploads/2018/07/canva-mariadb-ubuntu-1024x538.jpg)

If you plan on adding a relational database integration to your site, you will need to install a database management program. The open-source MariaDB installation is a popular alternative to MySQL. In this article, we’ll show how to install MariaDB on your Ubuntu Cloud VPS.

See the updated guide on [how to install MariaDB for Ubuntu 20](https://www.inmotionhosting.com/support/server/linux/install-mariadb-ubuntu-20/).

## How to Install MariaDB

1. As is common practice, you will want to make sure the packages in your package manager are up to date:sudo apt-get update
2. Next, run the installation command for MariaDB:sudo apt-get install mariadb-server
3. Once you’ve answered “Yes” (Y) to the prompt, the installation will proceed.
4. We can verify the services are running as intended with this command:sudo service mysql start
5. If you see no errors, this means MariaDB (which is a drop-in replacement for MySQL is running). You can log into MariaDB the same way you would with MySQL:mysql -u root -pAfter which, you will be prompted for the password for the MySQL root user.

Learn more from our [Cloud Server Hosting Product Guide](https://www.inmotionhosting.com/support/product-guides/cloud-server/).

Experience full control over your server environment and deploy the best operating and management systems that fit your needs with our reliable [Cloud VPS Hosting](https://www.inmotionhosting.com/cloud-vps)!
