Documentation and Source
Download
Overview
Creating a VirtualBox VM Running macOS Mojave

Overview

InstallerApp2ISO is an opensource utility for converting a macOS Installer application to a bootable ISO image.

It can also generate a VirtualBox vdi disk image for booting a macOS VM using an APFS file system.

Creating a VirtualBox VM Running macOS Mojave

There are a number of steps to create a working Mojave VM in VirtualBox. This guide assumes you have some familiarity with creating and maintaining VirtualBox VMs.

A comprehensive usage guide is include in the VirtualBox distribution and you should refer to this for things you don't understand about creating or running a VM.

Prerequisites

  1. Download VirtualBox and install it (see https://www.virtualbox.org)
  2. Also download and install the Oracle VM VirtualBox Extension Pack (from the VirtualBox download site)
  3. Download the current Install macOS Mojave from the the Apple App Store. You can skip this step if you already have the installer.
  4. Download InstallerApp2ISO from this site.

Create Mojave installation files

  1. Run InstallerApp2ISO and create an installer ISO from the Install macOS Mojave application.
  2. Run InstallerApp2ISO and create a VDI file from the Install macOS Mojave application. You will be prompted for a name and a size.
    It is a good idea to choose a name for the disk that reflects the name you will use for the VM. Avoid using spaces in the name if possible.
    Also, have a think about how big you want this VDI to be. Choose a reasonable size for your intended use of the VM.

Set up a new VM for macOS Mojave

  1. Run VirtualBox and make a new VM. Use the macOS 10.13 (High Sierra) template and choose a name for your VM that is similar (if not the same as) to the name you chose for your VDI. Avoid using spaces in the name if possible.
    • Do NOT add a virtual hard drive to this machine - you'll add it later.
    • Most of the settings are best left at their default values.
    • You MUST configure a USB 3.0 (xhci) controller.
    • Configure the number of CPUs you wish to allocate to the VM. 2 CPUs is a good number for the installer and can always be increased later.
    • Configure the RAM you wish to allocate to the VM. I suggest a minimum of 3GB but this is dependent on how much real memory is installed in your machine.
    • Configure the Video Memory to 128MB.
    • Do NOT overcommit your host resources - performance of both the host and the guest will suffer if you do.
    • Close the Settings window.
  2. Right-click your VM in the list of VMs. Select Show in Finder and the folder containing the configuration files for your new VM will open.
  3. Copy your newly minted VDI file into the VM folder. By default the VDI was created on your Desktop.
  4. Back in VirtualBox, open the new VM settings and add your new VDI file as the hard drive for your new VM. Be sure to choose the VDI file you copied into your VM folder in the previous step.
  5. Add a DVD drive to your VM (if you don't already have one) and assign your ISO to the drive.

Run your new VM

  1. Start your new VM and it should boot from the ISO installer, eventually leading you to the familiar macOS Installer.
  2. Jump through all the installer hoops and an initial macOS installation will be performed from the ISO to your VDI.
  3. After this first phase of installation your VM will reboot. Interrupt it (power off the VM or close its window).
  4. Back in VirtualBox, open the VM settings and remove the ISO from the DVD drive. If you don't do this, the VM will once again boot from the ISO.
  5. Reboot the VM with the ISO removed and the macOS installer should proceed to completion.

Post Installation Tweaks

Once you have succesfully installed macOS Mojave into a VM, you may wish to consider the following:
Consult the VirtualBox usage guide if you are unsure how to make these tweaks. You will also find useful information in the VirtualBox online forums.

  • Change the size of the macOS desktop.
  • Change the networking setup. The default is NAT.
  • Assign a serial number to your VM.
  • Install the VirtualBox Guest Additions. Currently this will fail. VirtualBox is not notarized and until it is, macOS 10.14.5 (and later) will refuse to install the kernel extension (kext) files.


A successful Mojave install in a VirtualBox VM



Download

InstallerApp2ISO is code-signed with my Apple Developer certificate and has also passed Apple's notarization process.


Download InstallerApp2ISO 1.0.1

InstallerApp2ISO 1.0.1 - Changes and Features

Enhancements

  • Support for creating a macOS 10.15 (Catalina) installer iso
  • Support for creating a macOS 10.14.5 (Mojave) installer iso
  • Added "Dry Run" switch to see what will happen without changing your system.
  • Version checking for new releases of InstallerApp2ISO

Download InstallerApp2ISO 1.0.0

InstallerApp2ISO 1.0.0 - Changes and Features
  • First public release