Use the final ElCapitan.iso as installer iso and attach it to the virtual SATA Port 1. Open Terminal, chmod the script and execute it: chmod +x ~/Desktop/prepare_elcapitan_cdr.shĭetach elcap.dmg from the VM. Paste the content in a text editor to a new document as plain text and save it as prepare_elcapitan_cdr.sh on your desktop. # Rename the ISO and move it to the desktop Hdiutil convert -format UDTO -o ElCapitan.iso Hdiutil detach /Volumes/OS\ X\ Base\ System Rm /Volumes/OS\ X\ Base\ System/System/Installation/PackagesĬp -rp /Volumes/esd/Packages /Volumes/OS\ X\ Base\ System/System/InstallationĬp -rp /Volumes/esd/BaseSystem.chunklist /Volumes/OS\ X\ Base\ System/Ĭp -rp /Volumes/esd/BaseSystem.dmg /Volumes/OS\ X\ Base\ System/ # Remove Package link and replace with actual files Hdiutil attach -noverify -nobrowse -mountpoint /Volumes/isoĪsr restore -source /Volumes/esd/BaseSystem.dmg -target /Volumes/iso -noprompt -noverify -erase Hdiutil create -o ElCapitan.cdr -size 8000m -layout SPUD -fs HFS+J Hdiutil attach "/Applications/Install OS X El Capitan.app/Contents/SharedSupport/InstallESD.dmg" -noverify -nobrowse -mountpoint /Volumes/esd
the user name in the last line and the path to Install OS X El Capitan.app (and the inner InstallESD.dmg file) in the 6th line): #!/bin/bash To create a bootable file use the following script. With AnyToISO program you can convert DMG to ISO and mount the resulting ISO image to your virtual machine (running Mac OS X).
#HOW TO INSTALL MAC OS DMG FILE ON VIRTUALBOX MAC OS X#
DMG is Mac OS X native disk image format while virtual machines (VmWare, Parallels or VirtualBox) are able to mount ISO images only.
The dmg file (Install OS X El Capitan.app/Contents/SharedSupport/InstallESD.dmg) is no bootable image. Mounting DMG image files to Vmware, Palallels or VirtualBox on Windows & Mac.