Booting Gentoo on OldWorld Macs

From SifWiki

Revision as of 15:06, 1 February 2009 by Siftah (Talk | contribs)
(diff) ←Older revision | Current revision (diff) | Newer revision→ (diff)
Jump to: navigation, search

This article was originally posted in early 2005, much of the information within still holds true up to and including 2006 installs of Gentoo

When installing Gentoo on an OldWorld machine I've sometimes encountered a problem getting the CD's to boot. Because the machine is OldWorld they won't just boot direct off the CD, BootX needs to be used instead. Using BootX and the following settings you should be able to get the CD booted to be able to continue your install. BootX settings are as follows:

root=/dev/ram0 rw init="/linuxrc" looptype=gcloop cdroot

In addition to this you'll need to set the ramdisk size to around 36000, choose the gentoo-2004.3 kernel and of course, select the correct ramdisk in the options popup!

You may also need to pass devfs=nomount to the kernel in BootX once you've finished installing Gentoo 2004.3 - hopefully this bug will be fixed in future but the stage3 images are currently a little b0rked - once booted, if you get a problem with PAM Authentification when trying to login you also may need to boot up off the LiveCD again and add 'pam' to your USE flags in /etc/make.conf, then re-emerge shadow and finally reboot and everything should work...

Update: I had some feedback off a website visitor asking me to mention that you should also copy the ramdisk image (initrd.img.gz - found on the LiveCD - it's the equivalent of "ramdisk.image.gz" you may have seen in other distributions) onto your hard drive somewhere, it doesn't matter where this is but I generally put it in my BootX folder. You also need to copy the correct kernel image to a folder name "Linux Kernels", this can either reside in the BootX directory, or preferably in your System Folder (putting it in the System Folder allows the BootX extension to find the kernels on boot).

Another tip when using BootX is to always format your Mac boot partition as HFS and not HFS+ (or "Extended"), this makes it much safer to mount your MacOS partition under Linux (HFS+ has in my experience been troublesome, an uncleanly mounted filesystem won't mount again and is a nightmare to fix) - also, call your active kernel "vmlinux" and have this chosen in BootX, then you can simply do the following to upgrade a kernel and never have to boot into MacOS, ideal for a headless system:

cd /usr/src/linux/
make clean && make all && make modules_install
cp -f vmlinux /boot/kernel-2.6.9
cp -f System.map /boot/System.map-2.6.9
cp -f .config /boot/config-2.6.9
modules-update
mount /mnt/macos
cp -f vmlinux /mnt/macos/System\ Folder\Linux\ Kernels/vmlinux
umount /mnt/macos

You'll need to add /mnt/macos to your /etc/fstab of course - hope that helps!