Print

How to install MariaDB Instead of MySQL8 in cPanel/WHM

How to install MariaDB Instead of MySQL8 During cPanel/WHM Installation (Updated for 2024)

Introduction

cPanel and WHM, the popular web hosting control panel software, typically come bundled with MySQL8 by default. However, some users might prefer MariaDB, an open-source community-developed relational database management system. MariaDB is known for its high compatibility with MySQL and offers additional features.

This recently updated guide explains how to choose MariaDB instead of MySQL8 during the initial installation of cPanel/WHM.

Before We Begin

It’s important to note that this guide applies only to new cPanel/WHM installations. If you already have cPanel/WHM installed with MySQL8, you cannot switch to MariaDB directly. You would need to consider a migration process, which can be complex.

Choosing MariaDB During Installation

Considering a brand new server that does not have cPanel installed, let us dive in and know how to install cPanel with MaridDB or Mysql version of your choice.

  • Access your server via SSH / Terminal. 

  • Run the below command which will create the a “cpanel.config” file which is crucial to define the version we need (MariaDB/Mysql).

mkdir /root/cpanel_profile
touch /root/cpanel_profile/cpanel.config
  • Once you’ve created the above file, edit the file using your favorite editor nano/vi.
nano /root/cpanel_profile/cpanel.config
  • Paste the below code in the file, save and exit the editor.
mysql-version=8.0

Important Note: You should select any version currently supported on your operating system by cPanel. Current supported versions are as below: (New installations of cPanel do not support installing or upgrading to MariaDB 10.3. Only pre-existing installations are supported. More information of the current versions can be found at https://support.cpanel.net/hc/en-us/articles/1500002121102-What-versions-of-MySQL-and-MariaDB-does-cPanel-support)

    • AlmaLinux 8, RockyLinux 8, CloudLinux 8
      • MySQL 8.0
      • MariaDB 10.3*
      • MariaDB 10.5
      • MariaDB 10.6
      • MariaDB 10.11
    • AlmaLinux 9, Rocky Linux 9, CloudLinux 9
      • MySQL 8.0
      • MariaDB 10.5
      • MariaDB 10.6
      • MariaDB 10.11
    • Ubuntu 20.04
      • MySQL 8.0
      • MariaDB 10.5
      • MariaDB 10.6
      • MariaDB 10.11
    • Ubuntu 22.04
      • MySQL 8.0
      • MariaDB 10.6
      • MariaDB 10.11
  • Great! Now simply continue with the cPanel installation process as you normally do. Follow the remaining on-screen instructions to complete the cPanel/WHM installation with MariaDB. 

Congratulations!

You’ve successfully installed cPanel/WHM with MariaDB in 2024 instead of the default MySQL8.

Additional Notes

  • While MariaDB is generally compatible with MySQL applications, it’s always a good practice to check for any specific compatibility requirements for the software you plan to use with your cPanel/WHM setup.

  • For more technical details and advanced configuration options related to MariaDB within cPanel/WHM, you can refer to the official cPanel documentation: https://docs.cpanel.net/whm/sql-services/mysql-or-mariadb-upgrade/

Conclusion

By following the above steps, you can ensure that your cPanel/WHM environment uses MariaDB from the very beginning. This guide provides a simple solution for those who prefer MariaDB over the default MySQL8 offering.

Table of Contents
Close
Get 75% + extra 10% Discount on web Hosting Plans by myglobalHOST

Extra 10% OFF

Coupon Code

EXTRA10

Applicable on

FLAT Rs 100 OFF

Coupon Code

FLAT100

Applicable on

How to Avail: Simply browse the most appropriate hosting plan for you and avail extra discount on all orders.

Expert Advice

+91-79862-84663

11AM to 6PM

Live Chat : 11AM to 6PM