Parallels / vagrant-parallels

Vagrant Parallels Provider

Home Page:https://parallels.github.io/vagrant-parallels

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for Parallels Desktop 17 (macOS M1 VMs)

giezi opened this issue · comments

commented

Hello together

I just wanted to ask when you guys support macOS M1 VMs (with Parallels Desktop 17) in the Vagrant Plugin?
For example we would like to create a new base-box from an macOS M1 VM.

Thanks and greetings
Reto

I should say that support of macOS guests on M1 Macs is experimental at the moment and development is in progress. And current implementation doesn't allow to work with them using regular product interfaces, like prlctl.

I cannot give any promises and ETA-s when it is going to become "production ready".

commented

Hi @romankulikov
Many thanks for the fast and detailed answer. Make sense if "prlctl" is not yet supported.

commented

@romankulikov Sorry to bother you, do you have any news regarding prlctl? Thanks!

@romankulikov Sorry to bother you, do you have any news regarding prlctl? Thanks!

Ho @giezi, alas no news to share yet.

I've found this issue after trying one of my Vagrantfiles on this new ARM Mac I've got. It took me a bit to get to this issue so posting my error string in hopes others will find it easier. A bit of research required on my part to work out how to "use an ISO or VHDX image file with an ARM-based operating system." with Vagrant (currently using generic/ubuntu2004).

There was an error while command execution. The command and stderr is shown below.

Command: ["/usr/local/bin/prlctl", "start", "eb03c1f5-b07b-4985-98c7-3a14bcea2211"]

Stderr: Failed to start the VM: Unable to start "vagrant-caldera_default_1649753116306_26719" because your Mac is equipped with the Apple M1 chip that does not support Intel-based operating systems. To create a compatible virtual machine, use an ISO or VHDX image file with an ARM-based operating system.
``

Sadly, using generic/ubuntu2004 did not work for me.

cedric.laczny:/Users/cedric.laczny/virtual_machines/singularity-vm/ $ vagrant init generic/ubuntu2004                           [12:28:16]

A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
cedric.laczny:/Users/cedric.laczny/virtual_machines/singularity-vm/ $ vagrant up                                                [12:28:22]
Bringing machine 'default' up with 'parallels' provider...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 0: shared
==> default: Clearing any previously set network interfaces...
==> default: Booting VM...
There was an error while command execution. The command and stderr is shown below.

Command: ["/usr/local/bin/prlctl", "start", "6accdee0-e1a5-49b5-a567-d5958e02ea24"]

Stderr: Failed to start the VM: Unable to start "singularity-vm_default_1674041214292_38740" because your Mac is equipped with the Apple M series chip that does not support Intel-based operating systems. To create a compatible virtual machine, use an ISO or VHDX image file with an ARM-based operating system.

Hi @claczny, @dnx-aiven
Your case is not directly related to this issue, since you are trying to use Ubuntu VM, not macOS VM.

But anyway, I'll try to help you. The box you are using, generic/ubuntu2004, is built for Intel-based Macs (amd64 arch) and it will not work on your newer M1-based Mac (arm64 arch). There are no generic/* boxes with arm support at this moment:

Start building ARM variants for some virtual machines/boxes.
^-- WE NEED A HARDWARE DONATION TO MAKE ARM64 IMAGES

https://github.com/lavabit/robox/tree/0a757b332c74024dda3bfa8d74da451b4c7e7db4#pending-tasks

Try using this box instead: bento/ubuntu-20.04-arm64, https://app.vagrantup.com/bento/boxes/ubuntu-20.04-arm64
If you still have errors there - please open a new issue for that.

Back to the original topic - running macOS VMs on M1-based Mac hosts:
In the recent release v2.2.6 we have implemented the support of this case, by #429.

Please try it with latest Parallels Desktop for Mac (v18 or higher) and open a new issue if it still doesn't work for you.
I'm closing this issue now.

Does this allow the capability to "vagrant up" using a .macvm or is there a way to convert it to a .pvm first?

@mjmerin Yes, the first one - this only adds a support of base boxes which already contain .macvm.

@legal90 awesome, thank you. Is there any documentation on to how to create base boxes with the new .macvm files?