• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion
  • Inviting everyone to the UX test of a new security feature in the WP Toolkit
    For WordPress site owners, threats posed by hackers are ever-present. Because of this, we are developing a new security feature for the WP Toolkit. If the topic of WordPress website security is relevant to you, we would be grateful if you could share your experience and help us test the usability of this feature. We invite you to join us for a 1-hour online session via Google Meet. Select a convenient meeting time with our friendly UX staff here.

Resolved Problems with MariaDB update on CloudLinux 8

Amadex

Basic Pleskian
Server operating system version
CloudLinux 8.8 (Anatoly Filipchenko)
Plesk version and microupdate number
Plesk Obsidian 18.0.55 Update 1
Hello, I just want to report that we had problems with updating MariaDB 10.3 to MariaDB 10.5 on CloudLinux 8. The server was perfectly working for 2 years on MariaDB 10.3 but due WordPress requirements we needed to update it.

The following commands were executed as root:
  1. MYSQL_PWD=`cat /etc/psa/.psa.shadow` mysqldump -u admin --verbose --all-databases --routines --triggers > /root/all-databases.sql
  2. service mysqld stop
  3. cp -v -a /var/lib/mysql/ /var/lib/mysql_backup
  4. service mysqld start
  5. /usr/share/lve/dbgovernor/mysqlgovernor.py --mysql-version=mariadb106
  6. /usr/share/lve/dbgovernor/mysqlgovernor.py --install
  7. service mysql restart
  8. MYSQL_PWD=`cat /etc/psa/.psa.shadow` mysql_upgrade -uadmin
  9. service mysql restart
  10. plesk bin service_node --update local
  11. plesk sbin packagemng -sdf
I've verified the version inside Plesk settings > database, and it was MariaDB 10.5.

After that problems were starting:
Random MariaDB crash with errors: Too many connections​
Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock'​
ERROR: Plesk\Exception\Database: DB query failed: SQLSTATE[HY000] [2002] Connection refused​
DB query failed: SQLSTATE[HY000] [2002] Connection refused​

I've did:
plesk repair installation​
pleak repair all -y​

and nothing was solved. After a server reboot, the MariaDB didn't start at all.

Then I've contacted CloudLinux support and they found out this:

Screenshot 2023-09-20 203938.png
Screenshot 2023-09-20 203950.png

After that, MariaDB 10.5 worked, but after every reboot I've needed to use mkdir/run/mariadb && chmod 775 $_ && chown mysql. $_ command, again and again.
Also all of the LVE limits were messed up, and to re-apply them I needed to run this command after every reboot: lvectl apply all

At the end, I've re-installed the server and imported the backup. So we're still on freshly installed MariaDB 10.3 which works OK.
 
Btw. moderators, fix the typo
  1. /usr/share/lve/dbgovernor/mysqlgovernor.py --mysql-version=mariadb106
to
  1. /usr/share/lve/dbgovernor/mysqlgovernor.py --mysql-version=mariadb105
Thanks!
 
Update:
My upgrade from 10.3 > 10.4 > 10.5 was successfully done without mysql governor from cloudlinux. So if you don't use mysql governor and their tools, don't install it at all and follow the AlmaLinux 8 tutorial instead.
 
Checked upgrade path with "mysqlgovernor", on my side it was ok, I just skipped Step 4, because upgrade consists of removing old/installing new packages and running service can interfere with this process. But almalinux approach is good enough too.
 
Back
Top