How To Dual Boot Hackintosh and Ubuntu
I wrote this post before geekhut recently crashed so I decided to repost the google cache because of the articles popularity.
Well because it is the holidays and I have nothing better to do than drink, I decided to have a few and install OSX86 on my Toshiba Satellite. The problem is Zend Development Environment is not yet available for OSX so I would have to dual boot.
Dual booting was truly a trivial task. There are many forums (Link) with some decent information as to how dual booting any OS with OSX86 can be done. I am comfortable with most Linux flavors so I figured grub would be my best bet. Unfortunately you can’t just point to your darwin mach_kernel and intramfs in /boot/grub/menu.lst, you actually have to chainload the darwin bootloader (which still isn’t so bad). This meant that I would have to install OSX86 first to ensure I could properly tell grub to pass on the bootstrap to darwin bootloader.
So heres how I did it.

PART I - Installing OSX86
1.Get Hackintosh, just search “ToH” on any torrent site and you should be able to find the second release candidate (in ISO format)
2. Burn ISO to DVD and set BIOS to boot from CD (Duhh)
3. Open the OSX Disk Utility and create say a 20 GB Partition, leave enough room for Ubuntu (another 20 gb). Format it for HFS+ Journalized and give it a cool name, like Hard_Disk ( I named mine sda1, remember this name for the next step).
4. Follow the on screen instructions until installation completes, but don’t reboot yet! There is a good chance you’ll end up with a blinking cursor. Open a terminal under the “Utilities” Menu and type :
#/usr/misc/script.sh Hard_Disk (or whatever you named your apple formated disc). Read the scripts output, you may see errors. If so the easiest way to make sure it will work is to unmount the drive, verify it, repair it (using the disc utility) and then run the script again.
5. Once you reboot you will be greeted by a gray screen with a white apple logo (hopefully) and you can proceed to configure your new apple Hackintosh as you wish.

PART II - Installing Ubuntu and configuring grub
1. Boot Ubuntu 7.10 into the live CD environment and follow through with a standard installation. When asked for a partitioning schema, select “Manual”
- This is how your current partition table may look
/dev/sda1 EFI (I am guessing apples boot partition, usually about 200 Mb)
/dev/sda2 Where OSX86 is already installed
/dev/sda3 unformatted / raw, this is where we will install Ubuntu
- Create a swapspace on dev hda3 to a standards size (Double the amount of your RAM)
- Create a root partition with whatever is left, it should be at least 10 - 20 GB
2. Once Ubuntu is installed, we will not immediately reboot, instead lets configure grub while were in a safe environment.
- Open a terminal (alt + f2 -> gnome-terminal)
- Make a directory to hold your Ubuntu partition
$ sudo mkdir /media/ubuntu
- Mount your Ubuntu partition
$ sudo mount /dev/sda4 /media/ubuntu
(sda4 may actually be sda3 depending on how you partitioned your Ubuntu side)
- List the contents of /media/ubuntu to make sure you mounted the correct drive
$ ls /media/ubuntu
If you see :
bin cdrom etc initrd lib media opt root srv tmp var
boot dev home initrd.img lost+found mnt proc sbin sys usr vmlinuz
You are on the right track.
else, try a different partition (hda2 / 3 / 4)
3. Great we’ve mounted our fresh Ubuntu installation and now we are going to edit our boot menu, type :
$ sudo gedit /media/ubuntu/boot/grub/menu.lst
A text editor will popup
- place a # before the “hidemenu” option so you will not have to press escape to access your boot menu.
- you will then look for the section where it lists your installed kernels (usually right at the bottom), at this point it should look something like :
i. your default ubuntu system
ii. your failsafe ubuntu system
iii. your memtest (memory test)
lets add the below text after the default ubuntu block (next line after “quiet”)
title Hackintosh
root (hd0,1)
chainloader +1
If you followed my partitioning scheme, this should work beautifully for you. (NOTE you can change “Hackintosh” to whatever you prefer)
That should be it, once you reboot the livecd, grub should popup and you will have the option to boot ubuntu or “Hackintosh” Enjoy!
Troubleshooting
Problem : When I select Hackintosh from the boot menu, I get an error.
Solution : Try changing /boot/grub/menu.lst to read :
title Hackintosh
root (hd0,2)
chainloader +1
You may have partitioned things weird but youll have to play with the (hd0,1,2,3,4) until it works for you.
Problem : I am still getting an error after changing the root parameter in menu.lst
Solution : Were you actually able to boot into OSX? if yes then keep playing with grub. If no, follow this tutorial closer.
f3a3EX Thanks for good post