Fog Creek Software
Discussion Board




Bug in MySQL that ships with Panther

Panther Server has a built-in mySQL build that can't count.
(see http://discuss.fogcreek.com/joelonsoftware/default.asp?cmd=show&ixPost=105101&ixReplies=19)

Here are the steps that another user did to replace his mySQL with the one from www.mysql.com:

------------------
Once I got the "new" version of MySQL running properly, the "number of
bugs" status screen started displaying proper values, and the sorting
within the context of the bugs began to work as expected as well.

OK, so here's how "real users" can do this. Note that you HAVE to back
up and restore your MySQL databases, because the new (read "default
MySQL Mac OS X installation") MySQL must store things in a different
location. I did this with mysqldump, specifying multiple databases on
one command line:

mysqldump --opt -uroot -p --databases fogbugz otherdatabase1 otherdatabase2 etc >dump.sql

I then shut down MySQL with:

mysqladmin shutdown -p

OK, installed the new MySQL from the binary DMG distribution. Note that
this puts everything in totally different locations. Installed both the
main package and the startup item.

Restarted per instructions with:

sudo /Library/StartupItems/MySQL/MySQL start

(even though you'd usually use SystemStarter to do it).

Following their instructions, I set the password since this was a new
install (even though it really wasn't):

/usr/ocal/mysql/bin/mysqladmin -u root password <password>
/usr/ocal/mysql/bin/mysqladmin -u root -h `hostname` password <password>

Finally, I restored the two databases with:

/usr/local/mysql/bin/mysql -uroot -p <dump.sql

Michael H. Pryor (fogcreek)
Monday, January 26, 2004

Yep, that user was me.

I've now been running with this setup for a week or so, and it's working well.

I'm definitely not an MySQL expert, but these steps worked for me to get things running properly.

Dave Nanian
Monday, January 26, 2004

Small comment on the above instructions:

Note that before you install the new MySQL, the default mysql is in /usr/bin/mysql. Afterwards, it's in /usr/local/mysql/bin. Because of this, you need to ensure you're running the correct code before and after the update (especially when accessing MySQL directly).

There are two typos in the above instructions: the path /usr/ocal/... should be /usr/local/... -- in addition, make sure when you set the hostname password that you use *back pops* as shown here. Otherwise, the command won't be evaluated properly.

Hope that helps.

Dave Nanian
Monday, January 26, 2004

*  Recent Topics

*  Fog Creek Home