Sunday, April 12, 2009

Dual-Booting Mac OS X and Ubuntu

Dual-Booting Mac OS X and Ubuntu

Mac OS X has a similar structure to Linux (it is BSD Unix based). Dual-booting Mac OS X and Ubuntu detailed instructions can be found here.

Installing Mac OS X after Ubuntu
  • If you decide to dual boot with OS X, choose ext2 as your partition type during the Ubuntu installation. (For this the Super Grub Disk CD is a useful utility. You can download the Super Grub .iso image file at forjamari.linex.org and burn the image to a CD-ROM.)
  • Once you have installed Ubuntu, edit the Grub start-up list:
sudo nano /boot/grub/menu.lst
and add the following lines:
title Mac OS X
root (hd0,0)
makeactive
chainloader +1

Reboot your Mac and go to the terminal in Max OS X (if you have any issues booting, boot from your Mac OS X DVD). Press F8 and enter -s. Enter:

fdisk -e /dev/rdisk0
flag 2 <--note that flag 2 is my Mac partition number two
quit
y
reboot
  • If are still unsure whether it is working correctly, use the Super Grub Disk CD and make grub active.
Installing Ubuntu after Mac OS X
  • If you get an error message during boot such as HFS+error in the bootloader, you can also use the Super Grub Disk for recovering Linux GRUB and the Windows MBR (Master Boot Record).
  • Once you have installed Ubuntu, edit the Grub start-up list:
sudo nano /boot/grub/menu.lst
and add the following lines:
title Mac OS X
root (hd0,0)
makeactive
chainloader +1
If you have issues with Mac OSX or Windows in GRUB, try changing the Mac OS X Grub entry
change root (hd0,0) to root (hd0,1)

This means you will boot into partition number 1. You can try any partition number until you get it right.

For more info, see this Mac OS X and Linux guide.

No comments: