Installing Mac OS X in a ZFS Partition
By Karim Berrah on Jun 02, 2010
ZFS has been removed for Mac OS X roadmap. Many people were waiting for it. Here is an alternative for any Apple HW owner to have Mac OS X running in a native ZFS partition, plus some nice features Mac OS X doesn't have yet.
" Single Use License. Subject to the terms and conditions of this License, unless you have purchased a Family Pack or Upgrade license for the Apple Software, you are granted a limited non-exclusive license to install, use and run one (1) copy of the Apple Software on a single Apple-branded computer at a time. You agree not to install, use or run the Apple Software on any non-Apple-branded computer, or to enable others to do so. This License does not allow the Apple Software to exist on more than one computer at a time, and you may not make the Apple Software available over a network where it could be used by multiple computers at the same time."
There is no statement that do not allows you to run Mac OS X, on an Apple Hardware, given the condition that it's running and installed only once. Actually, with VirtualBox 3.2(.2), it's working:
You can see in the above picture that the Apple HW is reconized, even if the SMC hasn't been detected at boot time, because OpenSolaris b134 do not forward any info about SMC (and he has no idea/driver about it).
So, this is especially possible, interesting, and legal if I do the following:
- Got an Apple MacBook Pro (MBP5.1) with a fats SSD disk
- Fresh install OpenSolaris Build 134 (you can delete your existing partitions and create a new Solaris Partition with the embedded GParted in the LiveCD)
- Once installed on my internal ZFS disk, install Oracle VM VirtualBox (at least version 3.2)
- Do a fresh install of Mac OS X leopard (an original copy of Leopard10.5 tested here).
- Update my Mac OS X 10.5 Virtual machine
New things I've noticed:
- You don't need to have any extra bootloader (like rEFIt) to natively boot OpenSolaris on your Apple HW, as the EFI will be able to boot the new grub 0.97.
- USB port is supported (only on OpenSolaris). You will be able, once activated in the VM running Mac OS X, to see/synchronise any iPod/iTouch/iPhone through the USB port. This option is not supported (and not legal) if you try to do it with VirtualBox on top of Mac OS X ...
- Installing a Mac OS X as a Virtual machine on an iMac, and then moving the Virtual Machine on a MacBook Pro, works, given that you keep the settings of the number of CPU unchanged.
- You don't have any Guest additions but your mouse will have automatic focus on and out when entering/leaving the guest window
- Sound works ! you have to choose the "Solaris Audio Driver" instead of "OSS Audio driver" inVBox and install the "ICH AC97 Audio driver" in your VM as explained here
- Screen resolution is limited to 1024x768
- Shared folder doesn't work. You have some alternatives: send files trought e-mail, use ftp between host/guest, or share manually a USB key between host/guest (only one will have visibility at a certain time)
- Having an SSD disk, performances of the Virtual Machine are perfectly acceptable (The host is MacBook Pro core 2 duo 2.66 GHz, 4GB of RAM)
I just wanted to highlight what is possible, through OpenSolaris, on the Mac OS X guest, that is actually technically impossible to be done on a native Mac OS X host, but still legal:
- I can finally run native Mac OS X applications from my OpenSolaris host, with the help of the Mac OS X guest :)
- I can finally keep a remote backup of my Mac OS X guest installation, by leveraging some features of ZFS, like "ZFS send/receive", without dependancy on which version of Mac OX I'm running (see Mac OS X Time Machine features/weakpoints).
- I can roll back after an Apple's update of even downgrade from Mac OS X 10.6 to Mac OS X 10.5
- I can use ZFS compression/Dedup/encryption to run/store my Virtual Machines, given the fact that I'm only running one version at a given time per Apple HW
- I can do a Teleportation of a Running Mac OS X Virtual machine from one Apple host to another one, given that my Virtual machine file is on a shared disk.
- I can play with DTrace on OpenSolaris to try to see what MacOS X is doing (when booting/when talking to an iPhone/iPad through the USB port ...), just try a "pfexec dtrace -l -m vbox\*" to see which probes are available for you
- I can change my Apple Hardware and restore all my Mac OS X Virtual Machine on the new HW.
So, try it :) you'll be surprised and pleased by the new features OpenSolaris brings to your Mac OS X Virtual machine ;)