GRUB

GRUB is an extremely nice boot loader, and the default FreeBSD boot loader leaves a lot to be desired. Fortunately this process is fairly painless, and will allow you to boot from your other disks. First we'll install GRUB. As root of course:

cd /usr/ports/sysutils/grub
make install clean

Now I'll assume you want to install GRUB on the MBR. This is probably just fine for most situations. FreeBSD is installed on my first disc, ad0.

sysctl kern.geom.debugflags=16
grub-install /dev/ad0

At this point booting will get you a slightly intimidatin GRUB prompt. It's not impossible to use, but it's also not very desirable. We'll want to set up a config file, so we can give ourselves a nice menu at boot time.

vi /boot/grub/menu.lst

GRUB will automatically read this file at boot time, and here is my configuration:

default 0
timeout 10

title=FreeBSD 5.3
root (hd0,1,a)
kernel /boot/loader

title=Windows 2000
map (hd0) (hd1)
map (hd1) (hd0)
rootnoverify (hd1,0)
chainloader +1

And now onto explanations. The first line says which option you want it to start on. Of course we'll take FreeBSD, as unexpected Win2k would be rather unpleasant. The next line is how much time in seconds it will wait before automatically choosing for you. 10 is a good modest choice if you're unsure. The next three lines pertain to FreeBSD. The title is what you want to show up at boot time. Root is asking where it is installed. hd0 signifies the first hard disk, and 1 signifies the second partition. a refers to the slice, and that will always be a.

Finally the last five lines are for Windows. Windows won't boot unless it thinks it is the first hard disk. Fortunately it's not all that intelligent, and GRUB can work around that. That's the two mapping commands. Note that I am mapping it from the second hard disk to the first. The rootnoverify just says the second disk and the first partition. Chainloader tells it to pass it over to the Windows boot loader.

There you have it, a fine boot loader without system beeps!