How to Upgrade MariaDB in Plesk Obsidian on AlmaLinux 9 or Ubuntu 24.04
Use Plesk Obsidian's built-in upgrade tool to move MariaDB to the current LTS release safely, including the two-pass path from MariaDB 5.5.
Plesk Obsidian can upgrade the MariaDB server it manages to the current long-term support (LTS) release from its own interface: it checks the databases, backs them up, switches the package repository and runs the post-upgrade steps for you. This guide walks through that upgrade on a current Plesk for Linux server (AlmaLinux 9, Ubuntu 24.04 or 22.04, Debian 12) and explains what to do if you are still on CentOS 7 with MariaDB 5.5.
The older method — adding a MariaDB repository file by hand on CentOS 7, running yum update and then mysql_upgrade to reach MariaDB 10.2 — was written for Plesk 12.5 and Onyx. Those Plesk versions, MariaDB 10.2 and CentOS 7 are all end-of-life, so do not follow it on a new server.
Where CentOS 7 and old MariaDB versions stand
- CentOS 7 reached end of life in June 2024. Plesk still lists it, but only together with a paid extended lifecycle offering. For a new server, Plesk's software requirements list AlmaLinux 8, 9 and 10, RHEL 8 and 9, Rocky Linux 8, Ubuntu 22.04, 24.04 and 26.04, and Debian 11, 12 and 13, among others. The practical replacement for a CentOS 7 Plesk server is a new AlmaLinux or Ubuntu server and a migration of your subscriptions.
- MariaDB: Plesk supports MariaDB 5.5 and later as a local database server, including the 10.6 and 11.4 LTS series. MariaDB 10.11 needs Plesk Obsidian 18.0.52 or later.
- The upgrade tool described below has been in production since Plesk Obsidian 18.0.60 and is available on all Obsidian servers from 18.0.71. It is not available on CloudLinux.
Requirements
- Plesk Obsidian 18.0.60 or later on Linux, with MariaDB as the local database server.
- Plesk administrator access and SSH access as
root. - A maintenance window. The upgrade usually takes around ten minutes, and Plesk and all hosted websites are unavailable while it runs.
Check your Plesk and MariaDB versions over SSH:
plesk version
mariadb --version
If plesk version shows a release older than 18.0.60, update Plesk first under Tools & Settings > Updates.
Step 1: Back up before you start
Take a snapshot of the whole server from your provider's control panel if you can; it is the fastest way back if anything goes wrong. In addition, write a dump of all databases to a place you control. Plesk stores the password of its admin database account in /etc/psa/.psa.shadow, so as root you can run:
MYSQL_PWD=$(cat /etc/psa/.psa.shadow) mysqldump -u admin --all-databases --routines --triggers > /root/all-databases-before-upgrade.sql
Check that the file exists and has a plausible size:
ls -lh /root/all-databases-before-upgrade.sql
The upgrade tool makes its own backup of all databases in /var/lib/psa/dumps as well. Make sure the disk has room for both copies:
df -h /root /var/lib/psa/dumps
Step 2: Run the upgrade from the Plesk interface
- Log in to Plesk as administrator and go to Tools & Settings > Database Servers (under Applications & Databases).
- In the row of the MariaDB server, click Upgrade now.
- Click the MariaDB version that Plesk offers. Plesk runs its pre-upgrade checks: it removes deprecated configuration options, analyses the package manager configuration and checks the databases with
mysqlcheck. - Plesk then lists safety measures. Confirm that you have SSH access to the server and tick the checkbox. If you use the SSH Terminal extension, keep its window open until the upgrade has finished.
- Open the Repair Kit extension in a new browser tab, log in with the administrator credentials, and tick the second checkbox. Keep that tab open too: it is your way in if the Plesk interface does not come back.
- Leave Back up all databases hosted on the server before the upgrade selected.
- Click Upgrade and wait. Do not restart services or the server while it runs.
- When the upgrade is complete, click Finish.
If the Upgrade now button is missing
On Plesk versions between 18.0.60 and 18.0.71 the feature may need to be switched on. Add the following lines to /usr/local/psa/admin/conf/panel.ini (create the file if it does not exist) and reload the Database Servers page:
[databaseManagement]
features.canBeUpgraded = true
The button is also absent on CloudLinux, where the tool is not offered, and when the server already runs the version Plesk would upgrade to.
If the server still runs MariaDB 5.5
MariaDB cannot jump from 5.5 straight to 10.6 or later. Plesk handles this in two passes: the first run of the tool upgrades 5.5 to 10.5. When it has finished, repeat the steps above and Plesk offers the current LTS version.
Step 3: Verify the result
Confirm the new version and that the service is running:
mariadb --version
systemctl status mariadb --no-pager
Ask the server itself, using the Plesk admin account:
MYSQL_PWD=$(cat /etc/psa/.psa.shadow) mariadb -u admin -e "SELECT VERSION();"
Then open a few hosted websites that use a database, log in to one application, and look at Tools & Settings > Database Servers to see the version Plesk now reports. Keep your dump and the backup in /var/lib/psa/dumps until you are satisfied; delete them afterwards to free the space.
Manual upgrade (CloudLinux and special cases)
Where the tool is not available, Plesk documents a manual procedure in its knowledge base. In outline, it is the same work the tool automates:
- Dump all databases and copy the data directory aside.
- Stop MariaDB and point the package manager at the repository of the target MariaDB series.
- Upgrade the MariaDB packages with
dnforaptand start the service. - Run
mariadb-upgradewith the Pleskadmincredentials so the system tables match the new version. (mysql_upgradeis the former name of this tool.) - Restart MariaDB and let Plesk re-read the installed package versions with
plesk sbin packagemng -sdf.
The repository definition and package names depend on your distribution and the MariaDB series, so take them from the current Plesk article rather than from an old tutorial: How to upgrade MariaDB on Plesk for Linux. The interface procedure is described in the Plesk administrator guide.
Frequently asked questions
Can I go back to the old MariaDB version if something breaks?
Not in place. Once the data files have been upgraded, the realistic ways back are the server snapshot or reinstalling the old version and restoring your dump. That is why the snapshot and the dump in step 1 matter more than any other step.
Which MariaDB version will Plesk install?
The tool offers the LTS version that your Plesk release supports; you pick from what it shows rather than typing a version. If you need a specific series, check the Plesk software requirements for your Plesk version first.
I am still on CentOS 7. Should I upgrade MariaDB there?
You can use the tool if your Plesk version provides it, but the operating system itself no longer receives regular updates. Treat a MariaDB upgrade on CentOS 7 as a stopgap and plan the move to a supported distribution.
Does the upgrade change my databases or users?
Your databases, users and passwords stay as they are. The upgrade replaces the server packages and updates the system tables. Applications that depend on behaviour of a very old MariaDB version may need their own updates, so test them after the upgrade.