Jump to content

Install Mariadb 10.11 in CentOS Stream 9 Almalinux 9 Rockylinux 9

Featured Replies

Posted
comment_24

MariaDB is an open source relational database management system (DBMS) that is a compatible drop-in replacement for the widely used MySQL database technology. MariaDB is based on SQL and supports ACID-style data processing with guaranteed atomicity, consistency, isolation and durability for transactions.

To Install Mariadb 10.11 in Centos 9 stream/almalinux 9/rockylinux 9 do this :
Now edit/create the Repo file :

Ensure you don’t have any other MariaDB repo file in /etc/yum.repos.d if exists delete or backup the existing repo file then create the repo file :

nano /etc/yum.repos.d/mariadb.repo


add this lines and save it :

[mariadb]
name = MariaDB
baseurl = https://rpm.mariadb.org/10.11/centos/$releasever/$basearch
module_hotfixes = 1
gpgkey = https://rpm.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck = 1


After that update Mariadb 10.11 :

yum clean all
yum install MariaDB-server MariaDB-client net-snmp perl-DBD-MySQL -y
yum update -y


No follow on screen setup by running this command :

mysql_secure_installation


** if you installed fresh copy of MAriadb just now and this command is asking password just hit Enter button

To login to the MariaDB server, enter the following command with the password that was set previously,

mysql -u root -p


Done you’ve installed Mariadb 10.11 on Centos 9/EL9

  • 8 months later...
comment_1050
On 6/2/2023 at 3:38 PM, Sandeep B. said:

MariaDB is an open source relational database management system (DBMS) that is a compatible drop-in replacement for the widely used MySQL database technology. MariaDB is based on SQL and supports ACID-style data processing with guaranteed atomicity, consistency, isolation and durability for transactions.

To Install Mariadb 10.11 in Centos 9 stream/almalinux 9/rockylinux 9 do this :
Now edit/create the Repo file :

Ensure you don’t have any other MariaDB repo file in /etc/yum.repos.d if exists delete or backup the existing repo file then create the repo file :

nano /etc/yum.repos.d/mariadb.repo


add this lines and save it :

[mariadb]
name = MariaDB
baseurl = https://rpm.mariadb.org/10.11/centos/$releasever/$basearch
module_hotfixes = 1
gpgkey = https://rpm.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck = 1


After that update Mariadb 10.11 :

yum clean all
yum install MariaDB-server MariaDB-client net-snmp perl-DBD-MySQL -y
yum update -y


No follow on screen setup by running this command :

mysql_secure_installation


** if you installed fresh copy of MAriadb just now and this command is asking password just hit Enter button

To login to the MariaDB server, enter the following command with the password that was set previously,

mysql -u root -p


Done you’ve installed Mariadb 10.11 on Centos 9/EL9

salute, and thank you so much for your very brief guide, just one more question please: what if would to use the latest Mariadb I mean(11.4.2).

secondly: there is no need to take back from old Mariadb?

 

thank you

  • 2 months later...
comment_1122

Hello, I am getting this error on Almalinux 9

Package perl-DBD-MySQL-4.050-13.el9.x86_64 is already installed.
Error:
 Problem: problem with installed package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best candidate for the job
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)
You have new mail in /var/spool/mail/root
Last metadata expiration check: 0:00:04 ago on Sun 13 Oct 2024 10:32:49 PM CEST.
Error:
 Problem 1: package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best update candidate for package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - cannot install the best update candidate for package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
 Problem 2: problem with installed package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best update candidate for package mariadb-server-utils-3:10.5.22-1.el9_2.alma.1.x86_64
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)


 

comment_1125
22 hours ago, maxwell said:

Hello, I am getting this error on Almalinux 9

Package perl-DBD-MySQL-4.050-13.el9.x86_64 is already installed.
Error:
 Problem: problem with installed package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best candidate for the job
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)
You have new mail in /var/spool/mail/root
Last metadata expiration check: 0:00:04 ago on Sun 13 Oct 2024 10:32:49 PM CEST.
Error:
 Problem 1: package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best update candidate for package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - cannot install the best update candidate for package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
 Problem 2: problem with installed package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System
  - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb
  - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream
  - cannot install the best update candidate for package mariadb-server-utils-3:10.5.22-1.el9_2.alma.1.x86_64
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)


 

If you encounter this problem

1. Remove Existing MariaDB Repository
First, run the following commands to remove the incorrect MariaDB repository:
 

sudo rm /etc/yum.repos.d/MariaDB.repo

2. Add Correct MariaDB Repo for AlmaLinux 9
Add the correct MariaDB repo file:

 

sudo nano /etc/yum.repos.d/MariaDB.repo

Add the following content to the file:

 

# MariaDB 10.11 for AlmaLinux 9
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.11/rhel9-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1

Save and close the file.

3. Update Packages and Upgrade MariaDB
Run the following commands to upgrade MariaDB:

 

sudo yum clean all
sudo yum makecache
sudo yum update MariaDB-server MariaDB-client

4. Restart MariaDB Service

 

sudo systemctl restart mariadb

If you receive this error after the process;

Error: Problem: problem with installed package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1.x86_64 - package mariadb-gssapi-server-3:10.5.22-1.el9_2.alma.1 .x86_64 from @System requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed - package mariadb-gssapi-server-3:10.5.22 -1.el9_2.alma.1.x86_64 from appstream requires mariadb-server(x86-64) = 3:10.5.22-1.el9_2.alma.1, but none of the providers can be installed - package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb - package MariaDB-server- 10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from @System - package mariadb-server-3:10.5.22 -1.el9_2.alma.1.x86_64 from appstream conflicts with mysql-server provided by MariaDB-server-10.11.9-1.el9.x86_64 from mariadb - package MariaDB-server-10.11.9-1.el9.x86_64 from mariadb obsoletes mariadb-server provided by mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 from appstream - cannot install the best update candidate for package mariadb-server-3:10.5.22-1.el9_2.alma.1.x86_64 (try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or ' --nobest' to use not only best candidate packages)

1. Force the Upgrade
You can force the upgrade using the following command:

 

sudo yum install MariaDB-server MariaDB-client --allowerasing

This command removes the conflicting mariadb-server package when installing MariaDB 10.11 and installs a new one instead.

2. Upgrade by Skipping Dependency Conflicts
If you still have problems, you can skip the dependency problems by adding the --skip-broken option:

 

sudo yum install MariaDB-server MariaDB-client --allowerasing --skip-broken

3. Restarting the Service After Installation
After the installation is successful, restart the MariaDB service:

sudo systemctl restart mariadb

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now