How to upgrade MySQL version via SSH (5.0/5.1/5.5/5.6)

IMPORTANT NOTE: After you upgrade MySQL, there is no supported way to downgrade to the previous version. There will be downtime of the MySQL service during the upgrade process.

You should take a backup of the existing database system before you proceed.

In order to upgrade MySQL version via SSH, you have to login as root in your server on console.

  1. You have to find file  /var/cpanel/cpanel.config and open it with a text editor like vi,vim, nano, etc.

For example: nano /var/cpanel/cpanel.config

and then change "mysql-version=5.5" to "mysql-version=5.6".

You have to save the file.

  1. Execute /usr/local/cpanel/scripts/check\_cpanel\_rpms --fix  under screen

  2. After the process is done you can review the MySQL version with: mysql -V

If you upgrade from MySQL 5.0 or 5.1 to MySQL 5.5 or 5.6 , you have to recompile your Apache and PHP. This could be done with the following command:


Note: If your MySQL version is 5.0 you should first upgrade to MySQL 5.1 and after that you will be able to upgrade to MySQL 5.5 and after that upgrade to 5.6. It is highly recommended to take backups of your databases before you start with the upgrade process.