Skip to content

Instantly share code, notes, and snippets.

@ariscript
Created October 7, 2024 22:03
Show Gist options
  • Save ariscript/395bcfdf120e20c5da49df50923f2e59 to your computer and use it in GitHub Desktop.
Save ariscript/395bcfdf120e20c5da49df50923f2e59 to your computer and use it in GitHub Desktop.
Running x86_64 .ova VMs on Apple Silicon

Running a x86_64 .ova VM on an Apple Silicon Mac

Run tar -xvf file.ova in the directory of your file, and it wil be extracted to a few different files. The only one we need is the .vmdk.

Dependencies

brew install qemu utm

We need qemu to convert the VM image, and utm to actually run it.

Convert Image to .qcow2

qemu-img convert -O qcow2 file.vmdk file.qcow2

This may take on the order of a minute depending on your system and image size.

UTM Setup

Open UTM, and press the + button to create a new VM.

  1. Choose Emulate Since we're going to be running a different architecture
  2. Choose Other as your OS, regardless of what you'll be running
  3. Give resources to this VM as appropriate (can be changed later) and generally continue through the menus.
  4. Once it's done, right-click it on the sidebar and click Edit.
  5. Scroll to the bottom of the sidebar, and add the .qcow2 file we created as a new drive.
  6. Delete the drive that was already present.
  7. In the QEMU settings menu:
    • Disable UEFI Boot
    • Enable RNG Device
    • Enable Balloon Device
  8. Save all settings.

This (should) result in a VM that boots to OS... at least it works on my machine.

You should now be able to delete all the auxiliary files that were created from the above commands, including the orignal .ova and all files derived from it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment