How to downgrade/upgrade MySQL on FreeBSD

The binaries we include for FreeBSD are just tarred up in a tar.gz file, no packages are used.
A sample filename of the package would be mysql-standard-4.1.18-unknown-freebsd5.3-i386.tar.gz

To change the version of mysql you're using, you'll first need to find the version you want, for the OS you're using.
You can find pretty much any old/new version of the binaries from http://downloads.mysql.com/archives.php?p=mysql-4.1&o=freebsd

Remember to get the "standard x86" version, and not the "max" version.

The process of the version change is as follows:

cd /usr/local
wget http://path/to/your/mysql-standard-4.1.18-unknown-freebsd5.3-i386.tar.gz
tar xvzf mysql-standard-4.1.18-unknown-freebsd5.3-i386.tar.gz
rm -f mysql 
ln -s mysql-standard-4.1.18-unknown-freebsd5.3-i386 mysql
cd mysql
rm -rf data
ln -s /home/mysql ./data

Then restart mysqld. If the restart doesn't work, try

killall -9 mysqld
killall -9 mysqld_safe
/usr/local/etc/rc.d/mysqld start


** Important: If you are moving from 4.0 UP to 4.1 or 5, you'll need to have updated mysql tables.  You'll also need to handle the new format of the passwords.  Info on that can be found here:
http://www.directadmin.com/features.php?id=466


Was this article helpful?

mood_bad Dislike 1
mood Like 0
visibility Views: 9254