Installation and setup of MariaDB on CentOS – detailed instructions

2 min


Mariadb

Installation and setup of MariaDB: Versions of MySQL after its own by Oracle became worse and worse. Constant falls and errors in the tables had a bad effect on the availability of sites, then it was decided to switch to MariaDB.

The result completely justified itself, MariaDB is very stable and well optimized. Three-year uptime without interruptions on several servers perfectly proves this.

Selecting the version of MariaDB

Maria Db

There are 2 branches of MariaDB – 5.x and 10.x.

5.x are versions that are as close to MySQL as the latest versions, they are fully compatible with MySQL. If you just go to MariaDB with MySQL – this version line is for you.

10.x – a new line of versions, which began after version 5.5. These versions do not completely copy all the new features of the latest versions of MySQL, but they contain their unique functions. They are still compatible with MySQL, but if you are just starting to use MariaDB, it’s better to start with version 5.5.

Installing MariaDB on a Linux server

MariaDB distributions are usually not found in the repositories of the major Linux distributions (for example, in CentOS 6 and CentOS 7). But, even if it were, it’s better to install MariaDB’s native repository in the system to always have the latest versions. To install the yum repository, follow the instructions:

1. Create a new repository file with the command:

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

Press the I key to enter edit mode for the vi editor.

2. Obtain the file text for your version of the Linux distribution using this link. You will need to select the name of the distribution, its version, and bit depth:

Mariadb

 

Copy the text for the repository file, paste it into your file, and press “: wq” to exit the vi editor with saving.

Now you can install MariaDB Server and the environment programs with yum:

YUM INSTALL MARIADB-SERVER MARIADB-CLIENT

Libraries for various programming languages can be installed for MySQL, they are fully compatible. For example, for PHP:

yum install php-mysql

Now you need to run the installed MariaDB server and go to its configuration:

SERVICE MYSQL START

If you did everything correctly, you will see the following message:

Command2

Setting up MariaDB

To get started with MariaDB, you need to set the root password. In detail about tuning and optimization of the database, I’ll tell you in a special article, these are not the first things.

Initial installation of MySQL password root:

The easiest way to set the root password is to use a special script, it is included in the MariaDB distribution:

/ usr / bin / mysql_secure_installation

Follow the instructions and set the root password.

If you still have questions or need clarifications – please ask or leave a comment.

I’m always happy to help!

Good luck!


Like it? Share with your friends!

What's Your Reaction?

cute cute
180
cute
lol lol
300
lol
love love
270
love
scary scary
180
scary
hate hate
30
hate
geeky geeky
60
geeky
omg omg
210
omg
CmsDaddy

Hello Guys, Here we write about ultimate guides about content management system (CMS) and other software such as WordPress, Joomla, Drupal, Oxwall, Skadate, Prestashop, Magento, CSS, HTML, Linux, CentOS, Ubuntu, Windows, macOS, Android, iOS, iPadOS, etc...

0 Comments

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

12 + twelve =

Choose A Format
Story
Formatted Text with Embeds and Visuals
Poll
Voting to make decisions or determine opinions
List
The Classic Internet Listicles
Personality quiz
Series of questions that intends to reveal something about the personality
Trivia quiz
Series of questions with right and wrong answers that intends to check knowledge
Ranked List
Upvote or downvote to decide the best list item
Open List
Submit your own item and vote up for the best submission
Countdown
The Classic Internet Countdowns
Video
Youtube, Vimeo or Vine Embeds