-
Notifications
You must be signed in to change notification settings - Fork 653
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Apple M1 / Hypervisor.framework support #1857
Comments
Hi @flying-sausages, this is definitely something we want to get going, but it will take some time. The API you mention is quite low level, the likes of hyperkit and qemu are what we'd need to implement support for it first. Did you see evidence that the hardware even supports virtualization already? From what we've read the dev kits did not, and I've not seen anyone confirming they have a VM running under Apple Silicon. |
I've seen a success story here which I think could be helpful https://forums.macrumors.com/threads/ubuntu-linux-virtualized-on-m1-success.2270365/ |
Another useful link from the same thread https://github.com/JacopoMangiavacchi/M1-Linux-SSH |
And another https://github.com/evansm7/vftool |
The M1 does have virtualization support. There have been a set of patches made to enable Hypervisor.framework (hvf) support to QEMU for aarch64: https://patchwork.kernel.org/project/qemu-devel/list/?series=391797 Also, there are now two different virtualization frameworks on macOS. There continues to be the lower-level Hypervisor.framework which is currently utilized by hyperkit via machyve/xhyve. Virtualization.framework is a new higher-level set of APIs which allows you to create VMs using the Virtio spec without having to deal with a separate hypervisor (such as xhyve) |
Yeah thanks @RyanMorash @flying-sausages for references, we're monitoring this space and will jump on it whenever things settle. One notorious source of problems for us is networking (NAT, bridging, DHCP, DNS), which hyperkit (through Hypervisor.framework) mostly solves and we'd love to continue using that. If, however, qemu gains support for all the bits'n'pieces we need, we may well go that route. |
https://gist.github.com/niw/e4313b9c14e968764a52375da41b4278#file-readme-md looks like there's QEMU support through some patches? Lively discussion happening underneath that. |
Docker is moving away from using HyperKit (which they originally created for Docker Desktop) and switching to Virtualization.framework: https://www.docker.com/blog/download-and-try-the-tech-preview-of-docker-desktop-for-m1/ |
I have tried to create VM with |
It seems docker have made good progress: https://docs.docker.com/docker-for-mac/apple-m1/ |
@nottrobin yeah we know everything we need now, just need to roadmap it - hoping for early next cycle. |
Is there a good place (other than this issue!) to watch for updates on this and when it might be released? |
There is also But I suppose if |
The complete guide for MacOS Apps Optimized for M1 Apple Silicon Macs |
This open-source implementation works quite well, wonder if it can be of any inspiration. https://github.com/utmapp/UTM |
@Saviq can you update us on this issue? No new Intel Macs will be designed, so us Mac Multipass users are kind of in the cold here. |
Hey @misterproton, all, we've scheduled the work on M1 support for the development cycle that just started. We'll be starting the work on it within a couple weeks. Stay tuned! |
@Saviq do you have any update or ETA for this one? |
Hi @misterproton we're actively working on it now. We should have a first build by July. |
👀 |
Happy to hear! Is there a chance this will show up in the 1.7.0 RCs? |
Hey @flying-sausages! No, it definitely won't be in the 1.7.0 release, but the plan is to make some beta packages available once I get this in a relatively good working state, most likely some time in July. I'm actively working on it 😃 |
How is going so far, are we still on track(no pressure😉)? |
I tried
The last lines appear only after I execute screen to connect to the tty. |
Hey all, We've dropped the first Release Candidate for Apple M1 support. It can be found at: This is a Universal package that supports both Arm and Intel Macs. The Intel side of things will now support a QEMU driver, but is not enabled by default. In order to enable the QEMU driver, you need to do: Please note that if you currently have Hyperkit-based instances, those will not be available when using the QEMU driver, but they will be preserved and can be used again when setting the driver to Lastly, there have a been a few reports during the beta testing that launching instances will suddenly start timing out where before it would work. There seems to be something going on with the Apple virtualized networking that we haven't been able to solve yet. We are tracking that in #2265 and if you run in to that, please report it there. Thank you, good luck, and let us know how it goes! |
Hello, I tested it and worked fine on a mac mini. Did you know if the bridge option to access the vm from an outside computer is implemented now ? thank you for your work |
Hi @franz2256, Thanks for trying it out and reporting your success.
Not yet and won't be in the initial release, but we plan on making that available in later release. |
Hey @townsend2010, thanks a lot for the RC! I tested it out an an ARM iMac and everything worked well. |
I was also able to get an instance running and open a shell successfully using the RC build that was posted here. Thanks! M1 MBP |
Can confirm I have multiple instances up and running using the RC build on an M1 MacBook Air. Nice work guys. |
I can't mount folder at this version.
When I give the access right for multipassd by It would still show the error message and auto cancel the access right in |
I tested the latest RC and it works well on the MacBook Pro M1, GJ. |
Since this runs on QEMU and not hyperkit, any chance we could get image launching support for the Apple Silicon release? |
Hello, can you please clarify. With this rc there is no network bridge and it is also not planned for the ga release? Its one of the key reasons I use multipass. Perhaps its only not availalble for these M1 architectures, but will continue for the current architectures (intel). Thanks. |
It's not there on Intel macOS today (unless you're using VirtualBox), either - but nothing changes there. The statement above was about Apple Silicon only. We plan to close the gap in the coming months. |
This is released in v1.8.0 now! |
Thanks @Saviq , fyi I use intel macOS + multipass only (no virtualbox). Multipass creates a network bridge to the VM and I can ssh/ping/etc straight to the VM's IP from my laptop. Super useful and a major reason I support multipass (and microk8s). Losing this feature would be a bummer :) Congratulations on the 1.8.0 release! |
Take care that could use only a single IP (it is in multipass documentation), the origin is from vmnet "The interface receives a private IPv4 address via DHCP. IPv4 traffic originating from the guest operating system must use the private IPv4 address. Packets sent from a different IPv4 address are dropped by the system." I have asked on apple dev forums if there is a way to use multiple IPs : https://developer.apple.com/forums/thread/693146 |
Ah yes! That bridged interface :) We will certainly keep that if at all possible. What we meant by "bridging" was additional networks that you can configure with
Thanks! :) |
Thanks @Saviq for your hard work! So can we suggest a change to https://isapplesiliconready.com/app/Multipass ? Is multipass a Universal app now? |
It is, yeah! |
Great. Submitted a change to https://isapplesiliconready.com/app/Multipass |
@Saviq is there a place to track Edit: actually, I believe this is a larger issue for me as a software engineer on the M1 platform as a whole. Without networks support, I don't think I could expose any resources launched by multipass on my local network, which would be a big limitation. |
@mlb5000 in progress, you should be able to try the package from here: https://github.com/canonical/multipass/pull/2462/checks?check_run_id=5375689050 |
@Saviq oh dang, thanks! I will try to do that this week and report back. |
@Saviq can confirm the Networks option is there now. Is there documentation somewhere for how to add a network/launch option to an existing instance? I'd like to either add |
This comment was marked as off-topic.
This comment was marked as off-topic.
I having error after installing and launching multipass: multipass start Any tips how to troubleshoot it? |
What are you trying to do?
Run Multipass to launch instances on top of Apple Silicon devices
What's your proposed solution?
Restrict multipass on AS to use the Virtualisation API intrdouced in Big Sur only and ensure ARM builds of ubuntu are being installed
Additional context
I have 0 experience in any of the underlying technologies that are used here. I know 1.5.0 has Big Sur support on Intel through the API above, and so I'm wondering what are the extra steps that need to be taken care in order to allow users to have ARM-based VMs.
ED: Latest build
1.8.0 build 787
The text was updated successfully, but these errors were encountered: