Install macOS High Sierra as VirtualBox guest (on macOS High Sierra)? I would like to install a VirtualBox guest of macOS High Sierra on my MacBook Pro that is also running macOS High Sierra so that I can experiment with MDMs, etc. without rendering my primary laptop unusable.  I've created an ISO of High Sierra by downloading the installer from the Mac AppStore and running the following commands:

hdiutil create -o /tmp/HighSierra.cdr -size 7316m -layout SPUD -fs HFS+J

hdiutil attach /tmp/HighSierra.cdr.dmg -noverify -nobrowse -mountpoint /Volumes/install_build

asr restore -source /Applications/Install\ macOS\ High\ Sierra.app/Contents/SharedSupport/BaseSystem.dmg -target /Volumes/install_build -noprompt -noverify -erase

hdiutil detach /Volumes/OS\ X\ Base\ System

hdiutil convert /tmp/HighSierra.cdr.dmg -format UDTO -o /tmp/HighSierra.iso

mv /tmp/HighSierra.iso.cdr ~/Desktop/HighSierra.iso


I've also created my VirtualBox guest on VirtualBox 5.2.0 r118431 with 8GB RAM and 2 processors.  However, when I attempt to boot from the ISO to start the install process, I'm met with a blank, black screen.

Is there something else I need to do in order to create my virtual macOS instance?
Your final HighSierra.iso is missing the complete InstallESD content (AKA the real High Sierra installer). You just copy a probably defunct and thus non-bootable base macOS system to the image.

I use the following shell script to create a working macOS installer iso file. Basically it's the same method as Apple's recommended way to create a bootable macOS installer thumb drive. The destination is a sparse dmg though.

#!/bin/bash

hdiutil create -o /tmp/HighSierra -size 5600m -layout SPUD -fs HFS+J -type SPARSE
hdiutil attach /tmp/HighSierra.sparseimage -noverify -mountpoint /Volumes/install_build
sudo /Applications/Install\ macOS\ High\ Sierra.app/Contents/Resources/createinstallmedia --volume /Volumes/install_build
hdiutil detach /Volumes/Install\ macOS\ High\ Sierra/
hdiutil convert /tmp/HighSierra.sparseimage -format UDTO -o /tmp/HighSierra.iso
mv /tmp/HighSierra.iso.cdr ~/Desktop/HighSierra.iso
rm /tmp/HighSierra.sparseimage


The script assumes the default location of the High Sierra installer in /Applications.

If you don't want to create a script, copy &amp; paste &amp; execute the commands in the script line by line in Terminal.



Before booting apply some mods to the VM:

VBoxManage modifyvm "name_of_vm" --cpuidset 00000001 000306a9 00020800 80000201 178bfbff



Remove the Floppy in System > Mainboard > Boot devices
enable USB3 in Ports > USB
set video memory in Display > Screen > Video Memory 128 MB
Set RAM and number of CPUs in System > Motherboard: 4GB; Processors: 2 CPUs