
I recently upgraded MariaDB from version 10.5 to 11.4 for a couple of RHEL9 servers. Here are the steps I used:
Add the MariaDB repo containing version 11.4 and exclude MariaDB 10.5 from the system default AppStream repository.
Uninstall MariaDB 10.5 and install version 11.4:
$ dnf remove mariadb
$ dnf install mariadb-server
Create socket:
$ mkdir /run/mariadb
$ chown mysql:mysql /run/mariadb
Start and enable MariaDB:
$ systemctl start mariadb
$ systemctl enable mariadb
Run the upgrade script:
$ mariadb-upgrade
Check if selinux is blocking mysql requests (it was in my case):
$ journalctl -t setroubleshoot
Make sure socket is created on reboot (overrides that in /usr/lib/tmpfiles.d/mariadb.conf):
$ vim etc/tmpfiles.d/mariadb.conf
# Type Path Mode UID GID Age Argument
d /run/mariadb 0755 mysql mysql -
Check status and logs:
$ systemctl status mariadb
$ vim /var/log/mariadb/mariadb.log
Leave a Reply