MariaDB failed to start after upgrading to php8.1.29

xml

Active member
On Debian12 upgrading from php8.1.28 to php8.1.29 cause MariaDB failure to start
× mariadb.service - MariaDB 10.11.8 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; preset: enabled)
Drop-In: /etc/systemd/system/mariadb.service.d
└─migrated-from-my.cnf-settings.conf
Active: failed (Result: exit-code) since Sat 2024-06-08 00:33:51 +03; 57s ago
Docs: man:mariadbd(8)
https://mariadb.com/kb/en/library/systemd/
Process: 590 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Process: 608 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 624 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=cd /usr/bin/..; /usr/bin/galera_recovery; [ $? -eq 0 >
Process: 700 ExecStart=/usr/sbin/mariadbd $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=7)
Main PID: 700 (code=exited, status=7)
Status: "MariaDB server is down"
CPU: 132ms

Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] /usr/sbin/mariadbd: unknown variable 'provider_bzip2=force_plus_permanent'
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] /usr/sbin/mariadbd: unknown variable 'provider_lz4=force_plus_permanent'
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] /usr/sbin/mariadbd: unknown variable 'provider_lzma=force_plus_permanent'
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] /usr/sbin/mariadbd: unknown variable 'provider_lzo=force_plus_permanent'
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] /usr/sbin/mariadbd: unknown variable 'provider_snappy=force_plus_permanent'
Jun 08 00:33:51 Acer mariadbd[700]: 2024-06-08 0:33:51 0 [ERROR] Aborting
Jun 08 00:33:51 Acer systemd[1]: mariadb.service: Main process exited, code=exited, status=7/NOTRUNNING
Jun 08 00:33:51 Acer systemd[1]: mariadb.service: Failed with result 'exit-code'.
Jun 08 00:33:51 Acer systemd[1]: Failed to start mariadb.service - MariaDB 10.11.8 database server.
 
PHP doesn't have any direct impact on the ability of the database server to start. Was MariaDB updated too? Something has happened after the last time MariaDB successfully started that has left it with an invalid configuration.

You can try journalctl -xeu mariadb.service to see more comprehensive logs which might contain more clues, but Googling around seems to show some potential issues with package upgrades leaving certain MariaDB plugins or their configuration missing unexpectedly.
 
I upgraded the mariadb version a few times, but on Centos Server... Debian operating system is the type I don't like very much. However, many upgrade protocols are published on the Internet.
 
  • Like
Reactions: xml
You should look at upgrade protocols like this; For example, your server is debian, your panel is directadmin, upgrade the version of directadmin on the debian server and mariadb on the panel.
 
  • Like
Reactions: xml
Was MariaDB updated too?
No, and I checked the forums was working fine before I run php upgrade

Debian operating system is the type I don't like very much
I have to prepare my self for the day when the only free open source OS is Debian.
You should look at upgrade protocols like this; For example, your server is debian, your panel is directadmin, upgrade the version of directadmin on the debian server and mariadb on the panel.
I dont use control panels for my server, I do every thing by command line.

Here is what ChatGPT suggested and it worked for me:
Open the file /etc/mysql/mariadb.conf.d/provider_bzip2.cnf with a text editor
Comment Out or Remove Problematic Lines:
# plugin_load_add=provider_bzip2
# provider_bzip2=force_plus_permanent
Do the same for other variables (lz4, lzma, lzo, snappy)
systemctl restart mariadb
I am not sure if that is the right fix because I think those variables are there for a reason
 
On Debian12 upgrading from php8.1.28 to php8.1.29 cause MariaDB failure to start
Check your my.cnf to see if it was changed. This doesn't look like something PHP would cause.

I don't know what those who would, I don't load any plugins into SQL. What version of MySQL are you running? For things like bzip that should all be in the PHP configuration ASFAIK. Very strange. This is why I just compile PHP on every new release and don't even bother with the package management.
 
  • Like
Reactions: xml
Doing more research I found out the following:
The files (provider_bzip2.cnf, provider_lz4.cnf, provider_lzma.cnf, provider_lzo.cnf, and provider_snappy.cnf) appear to be related to compression providers for MariaDB. These are configuration files that instruct MariaDB to load specific compression plugins.

Understanding Compression Providers​

Compression providers are plugins that allow MariaDB to compress data using various algorithms. These plugins are generally used to save disk space and potentially improve performance by reducing I/O operations. The named providers (bzip2, lz4, lzma, lzo, snappy) correspond to different compression algorithms.

Likely Reason for Presence​

These configuration files are new in MariaDB 10.11 and may have been introduced to provide support for various compression algorithms directly within the database server. However, if these plugins are not installed or not compatible with your MariaDB setup, they can cause the server to fail on startup.

Why These Files Are New​

The introduction of these files in MariaDB 10.11 could be part of an effort to expand support for various compression algorithms. If these are not part of your current or intended setup, safely commenting them out or removing them should not affect your database operations and will prevent startup errors.
Removing the provider files solve the problem and MariaDB is up and running normally now
 
Back
Top Bottom