Hi
I wont to upgrade my mysql server on Ubuntu 14.04 from version 5.5 to 5.6 how can i do that?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.
While MySql 5.5 is the default for Ubuntu 14.04, MySql 5.6 is available in the default repositories. It can be installed simply using:
If you have existing data in a MySql 5.5 database, it should be migrated automatically. Though it is always a good idea to make a backup before doing a major upgrade.
First make a backup of the data in your existing database:
Then after installing the newer version, you can restore if needed by running:
For more info on migrating MySql databases, check out:
step 1 : take a backup
mysqldump --lock-all-tables -u root -p --all-databases > dump.sql
step 2 : remove old mysql
sudo apt-get remove mysql-server sudo apt-get autoremove
step 3 : install new version of mysql
sudo apt-get install mysql-client-5.6 mysql-client-core-5.6
sudo apt-get install mysql-server-5.6
step 4 : restore your data
mysql -u root -p < dump.sql
This one worked for me:
and after that, I did this: