Mac OS X in Linux via VirtualBox (as guest OS)
Linux
Mac OS X
I recently installed a Windows virtual machine on my Linux laptop. I wanted to test out a virtualized Mac OS X machine via VirtualBox as well (just in case I ever needed to do something that can only be done on a Mac). My main references are this post and this post. Although they virtualize on a Windows host machine, it also worked on my Ubuntu 10.10 host laptop.
Things I needed:
- A Mac OS X 10.6 (snow leopard) installation dvd (RETAIL version, not the one that comes with the Apple machine). Buy a copy and rip it to iso.
- nawcom ModCD to be able to boot the installation DVD. The EFI that came with VirtualBox and the Empire EFI from the first post did not work.
- The latest myHack. I used version 1.1 (r123). Install this before the Apple update.
- Mac OS X 10.6.5 Update. Don't do OS upgrade via the Automatic Updater, and don't update without consulting the myHack website; things can break.
Some notes to myself:
- When creating the hard drive, use "dynamic" and just make it as big as possible. I originally did 20gigs and had to re-do to 100gigs. Since it is dynamic, you won't take up space on your host system until you the space get filled up on the guest. Although there is a way to resize the hard drive on a Windows guest, I wasn't able to do so on the Mac guest (different filesystem and there is that boot loader issue). Looking back in hindsight, I should've just made it 500gigs and move the virtualization on an external disk if I ever reach that (I highly doubt it!).
- To access files on the host, set up samba on the host and connect to it on the guest.
- I used dmg2img to convert dmg to iso (when needed).
- Follow the second post to change the resolution (modify
/Extra/com.apple.Boot.plist
and runVBoxManage setextradata "MacOSX64" "CustomVideoMode1" "1366x768x32"
on the host). "1366x768x32" is the resolution on my Toshiba Portege R705 running Ubuntu 10.10. Now I can go fullscreen. - Sound most likely won't work. I have no use for it anyways.
Good luck. I hope I won't have to use it much, but it's nice to do everything in one machine, running inside of Linux (as opposed to having multi-boot).