The Depenguinator, version 2.0
In December 2003, I wrote a script for remotely upgrading a linux system to FreeBSD. I gave it a catchy name ("depenguinator", inspired by the "Antichickenator" in Baldur's Gate), announced it on a FreeBSD mailing list and on slashdot, and before long it was famous. Unfortunately, it didn't take long for changes in the layout of FreeBSD releases to make the depenguination script stop working; so for the past three years I have been receiving emails asking me to update it to work with newer FreeBSD releases.
A few weeks ago, Richard
Bejtlich came forward with an offer to pay me to make the necessary
improvements (money doesn't solve everything, but offering money
certainly helps break the "I'll do it when I have some free time" / "I
never have any free time" deadlock). In the end I asked him to
arrange for a donation to the FreeBSD Foundation instead of paying me,
but his offer was enough of a prompt for me to spend ten hours revising
and testing the depenguinator.
The key changes from before are as follows:
Without further ado, here are the steps I needed to upgrade an
Ubuntu 7.10 system to FreeBSD 7.0-RC1:
If you find this useful, please consider
donating to the
FreeBSD Foundation and sending
me an email to let me know that you have done so -- it's remarkably
gratifying to see such a concrete demonstration that people appreciate
what I've done.
Now go forth and depenguinate!
In addition, various bits involving the FreeBSD boot process have
been cleaned up.
apt-get install curl
apt-get install bsdtar
apt-get install libc6-dev
apt-get install zlib1g-dev
curl http://www.daemonology.net/depenguinator/depenguin-2.0.tar.gz > depenguin-2.0.tar.gz
sha256sum depenguin-2.0.tar.gz
The computed SHA256 hash should be
aa5d98dd3998545600f5af1d406196832ef8bea59cb022bc3a5efb303ac57cf7.
tar -xzf depenguin-2.0.tar.gz
cd depenguin-2.0
mv depenguinator.conf.dist depenguinator.conf
nano depenguinator.conf
This configuration file contains basic networking configuration
parameters, so that the system can get back online after it boots
into FreeBSD.
curl ftp://ftp.freebsd.org/pub/FreeBSD/releases/i386/ISO-IMAGES/7.0/7.0-RC1-i386-disc1.iso > disc1.iso
sha256sum disc1.iso
Compare the SHA256 hash against the hash contained in the announcement
signed by the FreeBSD release engineer -- we've never found any signs
of Evil People deliberately tampering with release ISO images, but a
few years ago there was a mirror which was corrupting ISO images due
to a faulty network switch.
sh -e makeimage.sh disc1.iso 7.0-RC1 ~/.ssh/authorized_keys
swapoff -a
dd if=disk.img of=/dev/sda2
title FreeBSD
root (hd0,1)
makeactive
chainloader +1
to /boot/grub/menu.lst and changing the default line
to default 3.
shutdown -r now