Mount the CF, copy over preboot, and install GRUB

And now we need to mount the cf, copy over our preboot files and install the GRUB bootloader.

# mkdir /mnt/cf
# mount /dev/hdc1 /mnt/cf
# mkdir /mnt/cf/boot
# mkdir /mnt/cf/boot/grub
# cp /boot/grub/stage1 /mnt/cf/boot/grub
# cp /boot/grub/stage2 /mnt/cf/boot/grub
# cp /boot/grub/menu.lst /mnt/cf/boot/grub

#grub
grub> root (hd1,0)
grub> setup (hd1)

This makes the CF bootable. Now copy over the kernel and the compressed image.

# cp /boot/vmlinuz-2.6.8-2-xxx /mnt/cf/boot
# cp /mnt/cfimage.gz /mnt/cf/boot

Now it's all ready for booting. Turn off the computer, move the CF card to the primary master, and reboot..... Alternatively, you may be able to disable the primary IDE controller in the BIOS and boot from the secondary master which will show up as hda1. This was possible on my development system. Your mileage may vary.

I have left out the setup for copying files on partition #2 and #3 of the CF drive. This is as far as I have gotten on the procedure. Check back for updates. To be continued……