MariaDB is not designed for downgrading between major versions, and downgrading between two major versions is not tested in any way by the MariaDB developers. Several HestiaCP users have reported problems after downgrades, including GUI displaying incorrect data, connection failures, and phpMyAdmin access issues.
The Safest Approach: Backup and Restore Method
Here’s the recommended procedure if you absolutely need to proceed:
1. Complete Backup First
Create full database backup
mysqldump --all-databases --routines --triggers --events --single-transaction > full_backup_$(date +%Y%m%d).sql
Also backup HestiaCP configuration
cp -r /usr/local/hestia/data/users/ ~/hestia_users_backup/
cp /usr/local/hestia/conf/mysql.conf ~/mysql_conf_backup
2. Stop Services
systemctl stop hestia
systemctl stop mariadb
3. Remove MariaDB 11.4
apt remove --purge mariadb-server mariadb-client mariadb-common
apt autoremove
rm -rf /var/lib/mysql/*
4. Install MariaDB 10.5
Edit MariaDB repository
nano /etc/apt/sources.list.d/mariadb.list
Change to: deb [arch=amd64] https://archive.mariadb.org/mariadb-10.5/repo/debian/ bullseye main
apt update
apt install mariadb-server mariadb-client
5. Restore Data
systemctl start mariadb
mysql_secure_installation
mysql < full_backup_$(date +%Y%m%d).sql
6. Reconfigure HestiaCP
Update HestiaCP database settings
/usr/local/hestia/bin/v-update-sys-hestia-all
systemctl start hestia
Alternative Solutions (Recommended)
Before attempting this risky downgrade, consider these alternatives:
Option 1: Application Compatibility Layer
- Modify your application’s database connection to use utf8mb3 explicitly instead of utf8
- In MariaDB 10.6+, you can set the old_mode system variable to make utf8 imply utf8mb4
Option 2: Use a Different Server
- Set up a separate server with MariaDB 10.5 for this specific application
- Keep your main server on 11.4 for other applications
Option 3: Application Updates
- Consider updating the legacy application to support utf8mb4
- Many applications can be modified to work with the newer charset
Critical Warnings
- Data Loss Risk : Users have reported needing to recreate database users and restore phpMyAdmin/Roundcube configurations after downgrades
- HestiaCP Integration : The control panel may not properly recognize the downgraded version
- No Rollback : Once you start this process, rolling back becomes complex
My Recommendation
Given the high risk involved, I’d strongly recommend exploring application-level solutions first. If the legacy application absolutely cannot be modified, consider running it on a separate server with MariaDB 10.5 rather than risking your entire HestiaCP installation.
If you do proceed with the downgrade, ensure you have:
- Complete system backups
- A tested restore procedure
- Downtime window for troubleshooting
- Alternative hosting ready if things go wrong
- Please do not forget, MariaDB 10.5 is EOL and does not receive any security fixes anymore