A Fresh Cup is Mike Gunderloy's software development weblog, covering Ruby on Rails and whatever else I find interesting in the universe of software. I'm a full-time software developer: most of my time in recent years has been spent writing Rails, though I've dabbled in many other things and like most people who have been writing code for decades I can learn new stuff as needed.

As of October 2016, I'm not actively looking for my next job, but I'm still happy to chat about potential opportunities. I'm not able to relocate, so unless you're in the Evansville area, I'd need a completely remote gig. I have lots of experience working remote. Prefer full-time but I wouldn't be averse to an interesting contact gig. Drop me a comment if you've got something or email MikeG1 [at] larkfarm.com.

Navigation
« Rails 2.2 Migration Goodies | Main | Double Shot #306 »
Monday
Oct062008

Upgrading MySQL 5.0 to 5.1 on OS X

I'm too lazy to build from source if there's not a good reason, and for running MySQL on OS X, I've yet to come across a good reason. So, I just use the MySQL Community downloads. Over the weekend I upgraded from 5.0.37 to the latest 5.1 download, because I was hard up against a MySQL bug that was fixed in later builds.

Unfortunately, while just running the installer for 5.1 worked great, it pointed the new server at a brand new set of databases - orphaning the couple of dozen databases I was working with. This was Not Good. The fix comes in two parts.

First, create /etc/my.cnf, with a single entry pointing to the old database files:

[mysqld]
datadir=/usr/local/mysql-5.0.37-osx10.4-i686/data

Second, tell MySQL to upgrade the files:

sudo mysql_upgrade -u root

Reader Comments (1)

[...] Upgrading MySQL 5.0 to 5.1 on OS X [...]

PostPost a New Comment

Enter your information below to add a new comment.
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>