I spent the weekend (or a fair portion of it, anyway) converting the old desktop machine that Ghostwheel replaced into a server. Last night I pulled the plug on Gimp, the old 350MHz Pentium III that has been serving wonko.com for over a year, and replaced it with the new box, Serenity: an AMD Athlon XP 1800+ with more memory and lots more storage space.
I had expected to spend as much as a week gradually getting FreeBSD configured, installing applications, and migrating user accounts and settings, but I did it in less than two days and encountered only a few minor problems. FreeBSD deserves all the credit for this. I'm convinced there is no better operating system for servers. The ports collection makes things sinfully easy.
One of the problems I've often had with previous servers is that I forget how I've configured things. On a machine like Serenity, which handles web, email, and database services for wonko.com and a few hosted sites, the intricate web of dependencies and configuration files can quickly become difficult to manage. This time, I set out to document every configuration change from the beginning. Installing everything from ports allows me to use the port management tools to keep track of dependencies, and I created a set of web pages documenting every port I installed and every configuration option I set. This documentation has already come in handy several times, and the server hasn't even been operational for more than twenty-four hours.
The downside is that it could quickly become tedious to update the documentation every time I make a change to the server, which will probably be often, since I love to tinker. I'm thinking of writing a web-based tool to make the process easier.
I love it when things go smoothly, and this is the smoothest server upgrade I've ever done. Hooray for FreeBSD!
Comments
You want FreeBSD to bear your children?
Hehehe...don't hit me, I'm puny.
Re: You want FreeBSD to bear your children?
Two boxes!
I have motoko, who has all my production stuff, is fairly static in its configuration, sits contentedly on the wild internet, and runs as little services as possible. While her sister teletha, my other computer who has all my development work, is incredibly dynamic, and heavily firewalled from the Internet and my LAN.
So yes, there is a way around it. Just have a sacrificial lamb. :)
Re: You want FreeBSD to bear your children?
I've restrained myself to having a sacrificial hard drive - a simple clone of the one in the server - and then just taking daily backups of directories that change frequently, such as the MySQL datadir, /etc and /usr/local/etc, just to name a few.
CVS could be your friend
I have several times thought about this problem and considered using CVS for the config files. In that way it would also be simple to keep track changes and notes about why the change was made.
[find ~ -newerct '1 day ago' -print|Find] is another fine tool when you want to make sure you got all the files you just changed documented.
Re: CVS could be your friend
I suppose most of the configuration files live in /etc or /usr/local/etc, but web applications and a few other things usually store their config files in their own directories.
Re: CVS could be your friend
I actually keep all of my /etc directories in a subversion repository on a remote account. Having everything in revision control is nice because, as well as being able to quickly setup a system if I need to reinstall, I also get to backup from changes that break the system very quickly.
wiki
Try a wiki for making documentation easy to keep up to date.