https://kb.askmonty.org/en/installing-mariadb-with-yum/
We have YUM repositories for several YUM-based Linux distributions. To easily generate the appropriate MariaDB.repo entry for your distribution, use our online repository generator.
We currently have YUM repositories for CentOS 5, CentOS 6, RHEL 5, RHEL 6, Fedora 16, and Fedora 17.
Once you have your MariaDB.repo entry, add it to a file under /etc/yum.repos.d/
. (We suggest something like/etc/yum.repos.d/MariaDB.repo
.)
An example MariaDB.repo
file for CentOS 5 x86 is:
[mariadb] name = MariaDB baseurl = http://yum.mariadb.org/5.5/centos5-x86 gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB gpgcheck=1
The example file above includes a gpgkey
line to automatically fetch the GPG key we use to sign the repositories. This key enables yum
and rpm
to verify the integrity of the packages it downloads.
Installing MariaDB with YUM
With the repo file in place you can now install MariaDB like so:
sudo yum install MariaDB-server MariaDB-client
If you don't have the MariaDB GPG Signing key installed, YUM will prompt you to install it after downloading the packages (but before installing them).
After Installation
sudo /etc/init.d/mysql start
Manually Importing the MariaDB Signing Key
If you like, you can manually install the GPG key using therpm
application like so:
sudo rpm --import https://yum.mariadb.org/RPM-GPG-KEY-MariaDB