92

I'm trying to install OS X Mavericks in VirtualBox on Windows 8.1. I have VirtualBox installed and the VM set up, but I need an ISO file to install the operating system.

I've searched around and found one result one a website I hadn't heard of, but Google Chrome flagged it as malware. I found a file on CNet, but it's an upgrade file for machines that are running an earlier version of OS X.

Is there an official source for downloading OS X ISO files? If not, is it possible to get the required ISO file without already having access to OS X?

2
  • 1
    It isn't available to Windows users on the iTunes store.
    – Brian
    Apr 22, 2014 at 2:08
  • This seems very difficult with Sierra even when running VirtualBox on a mac and using the createinstallmedia utility included in the Sierra App Store download (as described at macworld.com/article/3092900/macs/… ). After creating a .cdr with disk utility (or a dmg with carbon copy cloner) the farthest I can get booting in VirtualBox is a bunch text then a gray circle with a cross against it.
    – JDiMatteo
    Oct 19, 2016 at 22:04

4 Answers 4

78

Does not work on Mavericks and Yosemite

There is no way to legitimately get the file without having access to a Mac, and a licensed copy of the OS via a purchase (unless you are a member of the Developer Program, for which you can expect to pay far more than the cost of the OS, what with it being free).

But if you can blag some access time on a Mac, then you can download the OS from the Mac App Store (You may need to Option+Click the Purchased section to force it to reshow them if you have downloaded them at least once already). Once you have the installer downloaded and sat in your dock, you can simply pick it apart and get to the image file that is inside it.

This is the official way to get the file direct from Apple, but there is still work to do to make it into an ISO:

  1. Once you’ve downloaded Mavericks, find the installer on your Mac. It’s called Install OS X Mavericks.app and it should have been downloaded to your main Applications folder or be sat in your Dock.

  2. Right-click (or Control+click) the installer, and choose Show Package Contents from the resulting contextual menu.

  3. In the folder that appears, open Contents > Shared Support; you’ll see a disk image file called InstallESD.dmg

    This dmg file is in essence an ISO file in s slightly different format. We'll need to convert it. Open up Disk Utility and:

  4. From the menu bar, select Images > Convert and point it to your .dmg file

  5. In the Save As dialog that follows, select DVD/CD master. Disk Utility will insist on saving the new ISO as a .cdr file, but it is really an ISO.

  6. When complete, you can rename it to .iso in Finder.

  7. Use an external HD or thumb drive which is in ExFAT format (Compared to FAT format, this allows for single files larger than 4GB). Copy the .iso file and access it on the other system.

For clarity, you can do the above on any version of OS X from 10.6.8 (Snow Leopard) onwards, so you can use an old image to get hold of a new image for example, if you have access to a different OS version than Mavericks.

10
  • I followed these instructions, but now I have the problem of getting the ISO file from the Mac to the PC.
    – Brian
    Apr 27, 2014 at 2:27
  • 1
    Burn it to a disc, use a thumb drive or external HD, stick it on DropBox - it's just a file now, usual file transfer options apply
    – stuffe
    Apr 27, 2014 at 9:29
  • I'm unable to add it to my flash drive. I've looked up why and it seems that I would have to reformat the flash drive to a format that can't be read by Windows, so that doesn't work for my situation. I'll try DropBox, but I remember it having some trouble with large files in the past.
    – Brian
    Apr 27, 2014 at 19:31
  • I've tried the process above, but while I do get a .cdr file, VMware Fusion won't boot from it, and using "file" just tags it as "data"; using "file" on a bootable ISO says "ISO 9660 CD-ROM filesystem data 'CD' (bootable)"
    – JJarava
    Jun 2, 2014 at 12:05
  • I've found an answer in the Apple discussion forums that seems to be much more convoluted (discussions.apple.com/message/23615133#23615133). Will let you know how it goes.
    – JJarava
    Jun 2, 2014 at 12:44
17

The answer above by @stuffe won't work on Mavericks. Apparently Apple has changed the format of the ESD image and it's no longer bootable.

Looking around I've found a couple of pointers on how to do the necessary conversions to get the result as something you can boot a VM off.

Depending on what's the purpose of the ISO file, if it's to reinstall a computer, it might be more useful to use a Bootable USB- For that, check How to: Create a bootable installation for OS X Mavericks 10.9 and above.

For the ISO file itself, I've mostly used the information found on this post on the InsanelyMac site, augmented with the information/tip on creating a Recovery Partition found on the Apple Support Communities.

Basically the process is to get the ESD image, and rebuild it to include some info that is now packaged as symlinks, and get that out as a ISO file. The author of the InsanelyMac post has automated the process into a bash script, that I'm pasting here for convenience/reference:

#!/bin/bash
ESD=$1
TMP=$2

if [ -z "$ESD" ] || [ -z "$TMP" ]; then
    echo usage: "'$0' /path/to/esd /path/to/tmpdir"
    exit 1
fi
if ! [ -e "$ESD" ]; then
    echo "file '$ESD' does not exist"
    exit 1
fi
if ! [ -e "$TMP" ]; then
    echo "dir '$TMP' does not exist"
    exit 1
fi

MPAPP=/Volumes/install_app
MPIMG=/Volumes/install_img
IMGSPARSE=$TMP/install.sparseimage
IMGDVD=$TMP/install.cdr

detach_all() {
  if [ -d "$MPAPP" ]; then hdiutil detach "$MPAPP"; fi
  if [ -d "$MPIMG" ]; then hdiutil detach "$MPIMG"; fi
}
exit_all() {
  echo +++ Command returned with error, aborting ...
  exit 2
}

trap detach_all EXIT
trap exit_all ERR

echo +++ Trying to unmount anything from previous run
detach_all

echo +++ Mount the installer image
hdiutil attach "$ESD" -noverify -nobrowse -readonly -mountpoint "$MPAPP"


echo +++ Convert the boot image to a sparse bundle
rm -f "$IMGSPARSE"
hdiutil convert "$MPAPP"/BaseSystem.dmg -format UDSP -o "$IMGSPARSE"


echo +++ Increase the sparse bundle capacity to accommodate the packages
hdiutil resize -size 8g "$IMGSPARSE"

echo +++ Mount the sparse bundle for package addition
hdiutil attach "$IMGSPARSE" -noverify -nobrowse -readwrite -mountpoint "$MPIMG"

echo +++ Remove Package link and replace with actual files
rm -f "$MPIMG"/System/Installation/Packages
cp -rp "$MPAPP"/Packages "$MPIMG"/System/Installation/

echo +++ Unmount the installer image
hdiutil detach "$MPAPP"

echo +++ Unmount the sparse bundle
hdiutil detach "$MPIMG"

echo +++ Resize the partition in the sparse bundle to remove any free space
hdiutil resize -sectors min "$IMGSPARSE"

echo +++ Convert the sparse bundle to ISO/CD master
rm -f "$IMGDVD"
hdiutil convert "$IMGSPARSE" -format UDTO -o "$IMGDVD"

echo +++ Remove the sparse bundle
rm "$IMGSPARSE"

echo "Done"
echo "Find your DVD at '$IMGDVD'"

I can confirm that the resulting image is indeed bootable within Fusion; it's in the process of being installed so I'm yet to see whether other "tricks" are needed to make it work (for example, if the result is lacking a Recovery Partition as stated in some of the threads).

UPDATE: The resulting VM boots, and appears to work "well". I have used the method described to create a recovery partition, but even though Carbon Copy "sees" a Recovery Partition on the (virtual) HD, it doesn't appear to work all that well, as booting the VM with Option key pressed doesn't do anything. Will look into it if I have time, but for the time being it appears that the .iso file I got is working.

6
  • Just make sure you have a lot GB left on your VM disk, since the above is doing a lot of copying. Especially the conversion step require 2x6GB to complete... ALso, since Macs use their own non-standard EFI to interpret the Apple comand key (hash-prezl), you can't use those when your host is a windows machine.
    – not2qubit
    Sep 17, 2014 at 20:26
  • Actually I believe it's more an issue of apple licensing; VMware won't boot OSX VMs on non-apple HW BUT there are patches for VMware Workstation that allow those VMs to boot (bypassing the check). Once done they work well.
    – JJarava
    Sep 17, 2014 at 20:28
  • FWIW. I've gotten Yosemite to boot in VB as well. But like Mavericks, there are additional hoops to jump. You need to give the right --cpuidset and a few other VM tweaks to make the Apple bootloader happy with the DMI data. What is good is, that you don't need to tweak any new kexts or special boot parameters.
    – not2qubit
    Sep 21, 2014 at 0:04
  • Apple published a page, Create a bootable installer for OS X. “With OS X El Capitan, Yosemite, or Mavericks, you can use a USB flash drive or other removable media as a startup disk from which to install OS X.” Jul 6, 2016 at 23:53
  • Hi, @BasilBourque - thanks for the pointer. I'll have to look into it; booting VMs off a USB media is sometimes a bit iffy, but at least creating it this way is way simpler than the .iso generating process!
    – JJarava
    Jul 7, 2016 at 7:40
13

There is no official way to run OS X on a virtual machine in Windows. The Apple EULA clearly states under section 2 B that you're allowed to:

(iii) to install, use and run up to two (2) additional copies or instances of the Apple Software within virtual operating system environments on each Mac Computer you own or control that is already running the Apple Software, for purposes of: (a) software development; (b) testing during software development; (c) using OS X Server; or (d) personal, non-commercial use.

Source: Apple Inc. Software License Agreement for OS X Maverics

This means that you can virtualize OS X only inside OS X on Mac hardware. Anything else breaks the license.

8
  • 1
    That explains why there's no easy way to get the ISO file.
    – Brian
    Apr 29, 2014 at 22:39
  • 3
    Apparently the license is interpreted as "you can virtualize OSX on Apple HW". An interesting take on how VMware uses Mac Minis with ESX to virtualize OSX for their building of Mac products: virtuallyghetto.com/2014/07/… Very interesting read!!
    – JJarava
    Aug 4, 2014 at 10:19
  • @JJarava My interpretation was that "you can virtualize OSX on Apple HW inside OSX" ([...] that is already running the Apple Software [...]). This seems to contradict with the article, which has a bare-metal hypervisor. But an interesting article!
    – onik
    Aug 4, 2014 at 19:30
  • How about in order to not break the "spirit" of Apple's license, I do the following. I own a MacBookPro, I'll literally destroy it, if I can retain rights to use exactly one copy of Mac OS X on my PC running in VirtualBox. That way, Apple makes their money on their hardware, and I get to use it on one, and only one, PC of my choosing. To prove I've destroyed my MacBookPro, I'll upload a video of me hitting it with a hammer until it's DOA. Thoughts?
    – MikeyE
    Jun 27, 2017 at 2:37
  • 1
    @MikeyE I'm not familiar enough with US laws to be comfortable answering that, I'd suggest getting an opinion from someone in the US, preferably a lawyer. There is a question related to this on SuperUser.
    – onik
    Jul 1, 2017 at 21:00
6

The same as given by stuffe.

You can format your flash drive to ExFAT format which allows for access both on Windows and Mac. The file size restriction of FAT is not present on ExFAT.

5
  • 1
    This is helpful, but I feel like it should be an edit to stuffe's answer rather than a standalone answer.
    – Brian
    Apr 29, 2014 at 18:50
  • 1
    @Brian : I couldn't comment with only 1 reputation
    – ganesh
    Apr 30, 2014 at 1:04
  • Let's leave it as a separate answer so Ganesh can gain some rep and comment next time.
    – stuffe
    May 1, 2014 at 16:32
  • 2
    I may be wrong, but I believe you can propose edits to other people's answers even with 1 reputation.
    – Brian
    May 1, 2014 at 20:56
  • @Brian : You are right. I'll edit the previous answer.
    – ganesh
    May 6, 2014 at 6:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .