Postfix & Tiger upgrade

| No TrackBacks

I've finally made the upgrade to Tiger on my mail server. That is, I've finally 'successfully' upgraded, it took a few attempts to get everything just right for what I wanted, and now that I'm done I thought I'd share a few details.

Probably the most important step is to make sure that you have a good backup before starting. For me, this step was critical, as it allowed me to back out at any time and get running again from the backup. I wasn't just upgrading from 10.3 to 10.4, but was also upgrading Postfix, MySQL, and PCRE all at the same time...

Tiger (10.4) includes version 2.1.5 of Postfix, for most folks this is probably more than sufficient. However, I wanted to upgrade to the Postfix 2.2.5 release, as it includes a few more bells & whistles that I wanted, I wanted to bring MySQL current, and also bring PCRE (Perl Compatible Regular Expressions) up to date. Basically, this meant upgrading my system to Tiger, upgrading/compiling each new piece, and finally getting it all up and running.

MySQL was a snap, thanks to a ready made Installer built for Tiger. I was upgrading from an earlier 4.1.x release, so there were no worries about my databases not working correctly, and it was a simple matter of copying over the data directory from the old path to the new and getting MySQL running.

PCRE compiled well, but prior to compiling I also upgraded to the latest version of Xcode to get all the latest libraries installed. Standard docs on how to install worked just fine.

The last and trickiest step was getting Postfix compiled properly. After trying a few times and having problems, I finally took a step back and found my error, a simple typo caused from a copy/paste error when trying to get both the MySQL and PCRE code compiled in. For reference, here's the correct MAKE instruction for that:

make -f Makefile.init makefiles \
    'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include -DHAS_PCRE -I/usr/local/include' \
    'AUXLIBS=-L/usr/local/mysql/lib -lmysqlclient -lz -lm -L/usr/local/lib -lpcre'

After that, it was just a matter of running Make, and then Make Upgrade.

The last and trickiest step was to get Postfix running at Startup again. The Tiger upgrade removed my Postfix StartupItem (included with the Postfix source code), so that just needed copied back to /Library/StartupItems, and I also removed the /System/Library/LaunchDaemons/org.postfix.master.plist file that Tiger includes for starting Postfix on demand, as I wanted this running all the time, and it also didn't seem to be launching my newly compiled version of Postfix properly. I also needed to edit the /etc/hostconfig file to change MAILSERVER=-NO- to -YES-, and after that Postfix launched perfectly.

In hindsight, I probably should have upgraded 10.4 to 10.4.2 before upgrading everything else, but no mail related updates seem to be part of the upgrade, so this shouldn't be a problem. But if you're planning on going to 10.4 and recompiling other software, get your OS fully current first, then start in on your other work, it'll save you the trouble later.

I used Mike Bombich's excellent Carbon Copy Cloner to clone my working system to a backup drive, upgrade that and was able to do all my testing on a backup drive prior to the actual upgrade, and at any time I could simply reboot from my primary drive and be up and running. Very useful when you can't have a production system down long but need to do some 'live' testing.

No TrackBacks

TrackBack URL: http://www.wrightthisway.com/cgi-bin/mt/mt-tb.cgi/344

November 2010

Sun Mon Tue Wed Thu Fri Sat
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30        

About this Entry

This page contains a single entry by Jim published on September 17, 2005 10:55 PM.

Keyspan USB Print Server was the previous entry in this blog.

TV Time is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Powered by Movable Type 5.031