My computer has three operating systems.
“Why do you need three operating systems?” one might ask.
First, because it’s cool, but mostly because it is quite practical for web and mobile development and playing games. Linux and OSX are both great environments for trying out new-to-me technologies like node.js, Ruby on Rails, MongoDB, and all sorts of hackerish command line tools. OSX has the added benefit of being able to deploy apps directly to my iPhone (as well as being the prettiest of the OSs). And when it comes to playing the games, nothing beats Windows. OSX is starting to get some love from Steam, and quite a few interesting indie releases show up on Linux, but if you want a guaranteed awesome PC gaming experience, you need Windows.
Also, from a web-development standpoint, the ability to do cross-browser testing comes in very handy. Plus, there are no development tools that are off-limits because the author decided to only release a Windows or OSX version.
So here is a basic rundown of my system, and how it was put together. Rather than develop a detailed howto, I’ll leave it to the many talented bloggers out on the internets to provide the step-by-step.
The most important element by far when installing OSX on a non-Mac is the motherboard. It’s like the foundation on a house – it needs to be sturdy or everything comes crashing down. Luckily, when I built my PC in early 2009, I purchased an Asus p6t, which just happens to be very compatible with OSX – as does the nVidia graphics card I picked up. Apparently Gigabyte mobos are all the rage with the hackintosh crowd, so if you are in the market for a new build, or want to check your current hardware, see the following links when considering hardware:
And if you are wondering if your existing hardware works, take a look at the following:
As for Windows and Ubuntu, most mainstream motherboards are accepted, but check your manufacturers website for compatibility information. Also, for discrete graphics in Ubuntu, go with nVidia, as they still support linux with proprietary drivers.
- OSX: 8GB or larger USB thumb-drive
- Windows 7: 8GB or larger USB thumb-drive or blank DVD
- Lubuntu: 1GB thumb-drive, blank CD, or blank DVD
Preparing a bootable USB drive with OSX Lion is definitely the most inconvenient step of the whole process. The ideal situation is to have a retail copy of OSX Lion, and an actual Mac available for temporary use. I actually cheated and had a friend at work create the OSX Lion installer for me (using his own hackintosh). Luckily, there are scads of online tutorials for creating a Lion USB installer using a nifty tool called UniBeast.
Once the OSX USB drive is created, download MultiBeast
and copy the file to the USB drive. This will be needed later.
Preparing Windows and Ubuntu installation media is less of a task. Because Windows 7 is a commercial operating system, you will need a licensed copy. I purchased a copy when it was released, but others may have an OEM version baked into a manufacturers recovery disc. If this is the case, you can get a clean Windows 7 ISO for re-installation from Microsoft. There’s a great tutorial on how to re-install Windows at PC World
. Creating a disc or USB drive for Ubuntu couldn’t be easier. Simply visit the Ubuntu download page
and follow the instructions for your chosen medium.
Adjust BIOS Settings
Unplug any hardware that is not necessary for the installation of the operating systems (extra hard drives, USB hubs, printers, etc…). Some BIOS settings may need adjusting as well. If available, make sure the following settings are true:
- Quickboot is disabled
- SATA is set to AHCI rather than IDE
- The primary hard drive has priority and is the first boot device (or 2nd behind the optical drive)
Prepare Hard Drive
Once all the installation media is ready to go, the targeted hard drive needs to be properly formatted. Because OSX is very finicky about drives and partitions, you must use the OSX disc utility to format your drive. In my case, I created five partitions on my 1.5TB hard drive.
- Insert the OSX Usb stick, power on, and tap the key for the alternative boot menu (F8 on my system)
- Boot the USB Disk containing OSX Lion and wait for the installer to load
- Open Disk Utility from the Applications menu
- Select your hard drive in the left-hand column
- Under Volume Scheme: separate the drive into at least 3 partitions. I use 4 partitions (one for each OS, plus a shared FAT32 drive for file storage).
- Click Options… choose GUID Partition Table, then click OK.
- Click the first partition (Untitled 1). Type LION for the Name. Choose Mac OS Extended (Journaled) for the Format.
- Click the next partition (Untitled 2). Name = WINDOWS7, Format = MSDOS (FAT).
- If you have an extra partition for shared files, do the same for Untitiled 3. Name=FILES, Format=MSDOS (FAT)
- The last partition must be free space. It is important that the last partition is free, as this is where linux partitions will go. Leaving it at the end of the disk will make things go more smoothly during the linux installation.
- Click Apply and close Disk Utility
- Shut Down (do not proceed with the installer)
Again, check out TonyMacX86′s blog for a nice guide on setting up a hard drive for multiple OSs
. The article refers to Snow Leopard and dual booting, but many of the steps are identical to my setup. The key is to set up the partitions first with Disk Utility, then instnall Windows and Ubuntu before OSX.
Install Windows 7
After setting up the hard drive partitions in the OSX Disk Utility, it’s best to set up Windows 7 next, as it has the most intrusive bootloader – which will get overwritten later. Start this process with the PC shut down.
- Insert the Windows 7 installation media (USB or DVD).
- Power up and boot into the Windows Installer.
- Choose Custom (Advanced) for the installation type.
- When presented with a list of drives, select the ‘WINDOWS7′ partition.
- Click Drive Options (advanced)
- Click format.
- Click next.
- Windows 7 will now install itself. You may need to remove the installation media if the PC is set up to auto-boot from the Windows 7 disk.
- When installation is complete, set up Windows, or Shut Down.
Install Ubuntu / Lubuntu
- Boot with the Linux installation USB or CD.
- Select ‘Install Ubuntu to the local hard drive’ option (or something similar)
- At the Allocate Drive Space screen, choose Something Else.
- Under /dev/sda click free space. (If you have more than one hard drive, choose the free space on the appropriate drive).
- Click Add…
- Type for new partition: Logical
- New Partition Size in Megabytes: Set this to the amount of RAM in your machine (e.g. 4096)
- Location for new partition: End
- Use As: swap area and click OK.
- You should see the swap space appear in your drive list. Click free space again.
- Click Add… again.
- New Partition: Logical
- New partition size in megabytes: it should default to the maximum space available. If not click the up arrow until the number no longer changes.
- Location for new partition: End
- Use As: Pick Ext4 if you work with huge files or need extra fast performance. Choose Ext3 if you want to access the linux file system from OSX (and possibly Windows with the right tools).
- Mount Point: Choose the forward slash - /
- Click OK.
- Device for boot loader installation: Choose the large linux partition that you just created (e.g. /dev/sda4).
- Click Install Now
- Proceed through the Ubuntu installation
- Shut down
Install OSX Lion
- Remove the Ubuntu installation media, and insert the OSX USB drive.
- Boot the computer with the USB drive and enter the OSX Lion installer
- Proceed through the installation process. Be sure to select the LION drive as the target for installation.
- When the installer ends, you will be at the Mac desktop.
- Copy the MultiBeast file from your USB drive to the desktop (or download it if you have internet access)
- Install and run MultiBeast.
- Here is where things get tricky. Everyone has different hardware, so there is no magic bullet. I selected EasyBeast to get the absolute necessities, and then chose specific options for audio and ethernet. Check this guide for a great explaination of the MultiBeast options.