Skip to content

Instantly share code, notes, and snippets.

@jthmiranda
Created November 6, 2019 03:35
Show Gist options
  • Save jthmiranda/4b1c27d26d61cf9ba52b7f76822d36df to your computer and use it in GitHub Desktop.
Save jthmiranda/4b1c27d26d61cf9ba52b7f76822d36df to your computer and use it in GitHub Desktop.
Settings for VM macOS
sudo /Applications/Install\ macOS\ Catalina.app/Contents/Resources/createinstallmedia --volume /Volumes/untitle --nointeraction
https://www.geekrar.com/create-macos-catalina-iso-file/
https://superuser.com/questions/1351460/how-can-i-install-a-macos-vm-guest-under-virtualbox-on-a-mac-host/1351461#1351461
VBoxManage setextradata "macOS Catalina" "VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" "MacBookPro11,3"
VBoxManage setextradata "macOS Catalina" "VBoxInternal/Devices/efi/0/Config/DmiSystemVersion" "1.0"
VBoxManage setextradata "macOS Catalina" "VBoxInternal/Devices/efi/0/Config/DmiBoardProduct" "Iloveapple"
VBoxManage setextradata "macOS Catalina" "VBoxInternal/Devices/smc/0/Config/DeviceKey" "ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc"
VBoxManage setextradata "macOS Catalina" "VBoxInternal/Devices/smc/0/Config/GetKeyFromRealSMC" 1
#!/bin/bash
installer="/Applications/Install macOS High Sierra.app"
hdiutil create -o /tmp/HighSierra.cdr -size 5500m -layout SPUD -fs HFS+J
hdiutil attach /tmp/HighSierra.cdr.dmg -noverify -mountpoint /Volumes/install_build
sudo "$installer"/Contents/Resources/createinstallmedia --volume /Volumes/install_build
mv /tmp/HighSierra.cdr.dmg ~/Downloads/InstallSystem.dmg
hdiutil detach /Volumes/Install\ macOS\ High\ Sierra
hdiutil convert ~/Downloads/InstallSystem.dmg -format UDTO -o ~/Downloads/HighSierra.iso
hdiutil create -o /tmp/Catalina -size 8500m -volname Catalina -layout SPUD -fs HFS+J
hdiutil attach /tmp/Catalina.dmg -noverify -mountpoint /Volumes/Catalina
sudo /Applications/Install\ macOS\ Catalina.app/Contents/Resources/createinstallmedia –-volume /Volumes/Catalina –-nointeraction
hdiutil detach /volumes/Install\ macOS\ Catalina
hdiutil convert /tmp/Catalina.dmg -format UDTO -o ~/Desktop/Catalina.cdr
mv ~/Desktop/Catalina.cdr ~/Desktop/Catalina.iso
https://www.reddit.com/r/MacOSBeta/comments/bwqx7i/create_a_macos_catalina_virtual_machine_in/
Download this file https://drive.google.com/drive/folders/18aszvAevDFUAigRvstsSM6MJQidylBSV if you are stuck with the infamous "startup.nsh"/EFI screen. Replace Catalina.iso with this image.
Start your VM and press "Esc". Type edit startup.nsh. Type the following lines.
echo -off
load fs1:\EFI\drivers\apfs.efi
load fs1:\EFI\drivers\AppleUiSupport.efi
load fs1:\EFI\drivers\ApfsDriverLoader.efi
map -r
fs2:
cd System\Library\CoreServices\
boot.efi
Press "Control F2" to save it and "Control F3" to exit from the text editor.
Now type exit. And you'll be brought to a bootloader-style screen. Select Boot Maintenance Manager, select Boot From File. Once you move your selection to the second entry, look to the right onto your screen and check if you are able to see the name of your formatted hard disk and proceed. macOS Install Data < Locked Files < Boot Files < boot.efi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment