Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I am needing to upgrade MySQL on Ubuntu, it is a production server and naturally cautious.

My many googles look to be essentially saying that I need to :

  1. Backup my current mysql database and tables/data

  2. Uninstall current mysql

  3. Install new MYSQL 5+

  4. Restore Databases/ tables and data

  5. Hope and Pray I got it right ??

Something doesn't seem right, sounds like a lot of down time and risk

Am I missing something, or any simple solutions?

Upgrading from MySQL 4 to 5 on Ubuntu 10

Many Thanks,

Rob

share|improve this question

migrated from stackoverflow.com Jun 22 '12 at 7:46

This question came from our site for professional and enthusiast programmers.

    
what's the problem? if you have backups then there is no risk factor. How big is the database? –  Flukey Jun 9 '12 at 10:30
    
Sound like your assumptions are correct. As long as you have proper backups, you should be good to go. –  rai Jun 9 '12 at 10:34
    
risk factor is my limited DBA knowledge on the setup side. I make regular sql dumps as backups and the box itself is backed up regularly. Not a huge database so file size is no problem. Just need a sanity check that those steps are the only way ? –  Rob Sedge Jun 9 '12 at 10:34
    
I don't think praying will be of any help. –  ThiefMaster Jun 22 '12 at 7:46
add comment

2 Answers 2

The upgrade process depends on how you installed your mysql distribution.

If you installed the ubuntu mysql distribution you don't need to upgrade that way (but always create the backup copy of all your dbs!). You need to upgrade that way only if you installed the mysql.com mysql distribution (ex. tar.gz).

If you installed mysql packages distributed by ubuntu (you can check it running dpkg -l | grep -i mysql-server) you may just need to use the ubuntu package manager to upgrade mysql.

share|improve this answer
    
Thanks, Appreciate the info. I will give that a look. –  Rob Sedge Jun 9 '12 at 10:41
add comment

The upgrade of the server itself should be a piece of cake, even for the casual admin.

However...

There are many, many changes between 4.x and 5.x. I would not expect to be able to import a v4-dump into a v5-server straight out-of-the-box.

Be prepared for a strong head ache during data migration. Also, prepare your devs for significant (I'm tempted to write "massive") reworks on their applications. Some features have gone. Some features have changed.

Be sure to read the Changelog carefully before engaging the procedure ! Read ALL pages related to ALL versions between your current and your actual target version. Also, follow the link "Upgrading from MySQL 4.1 to 5.0", found at the bottom of the Changelog page (sorry, not enough rep' to post more than two hyperlinks :( )

Tip : it is possible to run multiple instances/versions of MySQL on the same system, in case you don't have a spare server at hand to play with.

share|improve this answer
    
Thanks Yak! The idea of running multiple appeals. Sounds a much kinder migration , meaning I can decommission the old once up and running .. still looking into the options here. Fab info, cheers. –  Rob Sedge Jun 9 '12 at 11:06
add comment

Your Answer

 
discard

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