Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've decided to do the update of MySQL from 5.5 to 5.6 on my CentOS server. How can I backup MySQL5.5 in case I want to downgrade, and how can I install MySQL 5.6?

Is there a way to use yum for this? Will upgrading to 5.6 break cPanel?

The steps on the MySQL website is pretty vague, and I am limited experience in installing things.

share|improve this question
Have you tested this yet with cPanel? I'm in the same situation (I need full-text search on innoDB tables) and am trying to find out if the upgrade causes trouble with cPanel. – supertrue Nov 5 '12 at 15:52
up vote 2 down vote accepted

There is no way to run multiple MySQL installations using yum on a single instance. But, it's very easy to install and uninstall current and future versions via yum or rpm.

It seems you are going about this in a very wrong way. First do this on a staging machine. Document the steps and time taken in detail. Do this multiple times if you have to improving your steps each time.

[1] Backup your MySQL data using mysqldump
[2] Upgrade your MySQL to 5.6
[3] Restore the data 
[4] Verify data integrity and ensure all your applications work 

Then, do this on production server with the same steps as you did in your final staging trial.

Rollback is as simple as installing the current version of MySQL back and restoring your dump.

This way, you verified the upgrade works, you verified your applications work .. cPanel and what not.

share|improve this answer
Is there an alternative if I do not have staging server? – Nyxynyx Aug 14 '12 at 17:36
Try this on your laptop/desktop with virtualbox or VMware player with same CentOS version and architecture as your production box. You can recover your production backup if it's not too big on the VM to ensure you work with production data and it is as real as it can get. – Chida Aug 14 '12 at 18:10

cPanel should be fine with MySQL 5.6 but you would need to confirm on your dev/test/staging environment where you're going to trial the upgrade process first =)

cPanel support suggests doing the MySQL upgrade their way:
You would need to be using a yum installed version of MySQL under cPanel at the moment to be able to replace the mysql binaries with yum. You will need to cover the MySQL config and data yourself.

From To upgrade to 5.6 from any previous version, MySQL recommends that you dump your tables with mysqldump before upgrading and reload the dump file after upgrading.

If I were doing a MySQL upgrade manually it would involve the following:

run mysqldump --add-drop-table --all-databases > dump.sql
stop mysql
Backup 5.5 config
Backup 5.5 data directory
Remove 5.5 rpms
Install 5.6 rpms
Start mysql
run mysql –default-character-set=utf8 < dump.sql
run mysql_upgrade

doesn't work?
stop mysql
remove 5.6 rpms
install 5.5 rpms
restore 5.5 config
restore 5.5 data directory
start mysql

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.