Skip to content

Instantly share code, notes, and snippets.

@fatso83
Created October 9, 2021 07:31
Show Gist options
  • Star 14 You must be signed in to star a gist
  • Fork 6 You must be signed in to fork a gist
  • Save fatso83/49980bbf065022d36c3a42369479a8df to your computer and use it in GitHub Desktop.
Save fatso83/49980bbf065022d36c3a42369479a8df to your computer and use it in GitHub Desktop.
Installing Vagrant on Apple Silicon Macs (M1, M1X, etc)

VirtualBox only supports the x86 platform, so the default installation instructions for Vagrant does not work on Apple silicon. Thankfully Vagrant has a VMWare Provider (more on providers here), and so if I can get VMWare running on my M1 MacBook, I should be able to run Vagrant as well!

These are my notes during figuring this out.

Get the VMWare Tech Preview released in September 2021!

We are in luck, as VMWare released this just a few weeks ago.

  • See their blog entry
  • register on their site to get an account
  • download and install

Installed VMWare provider

Setup basic Ubuntu image (failed)

vagrant init hashicorp/bionic64

$ vagrant up --provider vmware_desktop
Vagrant encountered an unexpected communications error with the
Vagrant VMware Utility driver. Please try to run the command
again. If this error persists, please contact support@hashicorp.com
@epsimatic
Copy link

Just saying that Canonical's Multipass works on Apple M1 with no hacks required, does basically the same stuff (but worse), and is easy to set up

@h3ct0rjs
Copy link

It seems like virtualbox is now supporting to run on M1 chips.

@fatso83
Copy link
Author

fatso83 commented Nov 15, 2022

@h3ct0rjs Links to that? Thought I read it would only ever be X86. But maybe they went the Rosetta route?

@h3ct0rjs
Copy link

@fatso83 https://osxdaily.com/2022/10/22/you-can-now-run-virtualbox-on-apple-silicon-m1-m2/ you can download the dev version from the website, in my case I recently move to a M1 chip, I use this with vagrant all the time but I’m currently checking if this works

@asmild
Copy link

asmild commented Nov 17, 2022

@h3ct0rjs Does it work? I didn't manage to make vagrant-virtualbox bundle work, I get VERR_UNSUPPORTED_CPU

@shoesCodeFor
Copy link

shoesCodeFor commented Feb 2, 2023

@asmild it works for me on M1. VirtualBox 7 beta: https://www.virtualbox.org/wiki/Downloads, I have Vagrant 2.3.4 and no plugins, yet.

I can spin up an arm based ubuntu 22 VM, but I'm getting some other errors. VMWare has always been a little ahead of the curve on macOS VMs. I'm hoping Fusion comes out of beta soon.

@mic345
Copy link

mic345 commented May 1, 2023

Just incase you stabled upon this thread, here is a quote from November 2022 by a Virtual box moderator on their forum:

VirtualBox is not and never has been an ARM hypervisor. The M1/M2 developer preview relies on an Intel code simulator module to run x86 (32bit) single core guests. Incredibly slowly. It's currently more of a toy than a serious solution to any problem.

https://forums.virtualbox.org/viewtopic.php?f=8&t=107344#p528167

@p2made
Copy link

p2made commented Aug 25, 2023

@fatso83
Copy link
Author

fatso83 commented Aug 25, 2023

@p2made I would hope so, it has been two years since I posted 😸

This has been working for quite a long time now. Thanks for the updated link! I won't update the original post anyhow, to not invalidate later stuff.

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