The version of the MariaDB server provided in default CentOS repositories is version 5.5.
Follow the steps below to install and secure MariaDB 5.5 on CentOS 7:
- Install the MariaDB package using the yum package manager:
yum install mariadb-server
2. Once the installation is complete, start the MariaDB service and enable it to start on boot using the following commands:
systemctl start mariadb
systemctl enable mariadb
3. Verify that the installation was successful, check the MariaDB service status by:
systemctl status mariadb
Secure your installation. Run the mysql_secure_installation
script which will perform several security related tasks:
mysql_secure_installation
You will be prompted to set up the root user password, remove anonymous user accounts, restrict root user access to the local machine, and remove the test database.