Skip to content
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

[Feature Request] Mac support on M2 and M3 #4426

Open
gedw99 opened this issue Feb 6, 2024 · 3 comments
Open

[Feature Request] Mac support on M2 and M3 #4426

gedw99 opened this issue Feb 6, 2024 · 3 comments

Comments

@gedw99
Copy link

gedw99 commented Feb 6, 2024

Feature Request

Mac support.

The Apple M1 CPU does not support hardware assisted nested virtualisation at all.
The Apple M2 and M3 CPUs support the v8.4-A level of hardware assisted nested virtualisation.

Describe the desired solution

Please see utmapp/UTM#6053

Basically I need to run firecracker on Macs as well as use it with UTM. I know firecracker is a Server only use case in general, but it would really make development of Firecracker on a Mac so much easier.

I have use cases where I want a Mac to act as an edge server also for production.

Describe possible alternatives

none.

Additional context

Checks

  • [ x ] Have you searched the Firecracker Issues database for similar requests?
  • [ x ] Have you read all the existing relevant Firecracker documentation?
  • [ x ] Have you read and understood Firecracker's core tenets?
@xmarcalx
Copy link
Contributor

xmarcalx commented Feb 12, 2024

Hi @gedw99 ,

Thank you very much for your request. It is always interesting see the penetration of Firecracker use, outside of its original intentions.
Similar request, was proposed while ago in #2845.

Unfortunately as you may be already aware, Firecracker heavily rely on KVM to perform its virtualization and emulation duties. KVM is not supported on MacOS and it is instead replaced by Hypervisor Framework which is quite different.
This means that supporting Firecracker to natively run on MacOS is actually a significant development task, which will also require significant expansion of our testing and maintenance strategy because we will basically need to validate any Firecracker feature against KVM and Hypervisor framework.
While we understand that this capability would help and improve the quality of life of MacOS developers, the cost and burden associated to it, is not backed by a valid business need because, as you said, the majority of servers run Linux nowadays and there is still the (intricate) opportunity for MaOS users to launch a Linux VM and develop inside it.

I do not know if it helps, but in the past, there were some attempts close to Firecracker to support a VMM based on Hypervisor framework. As you know, Firecracker use KVM bindings imported from our rust-vmm crate. One of our ex intern built runst-vmm bindings for Hypervisor Framework and a VMM which can run on x86 MacOS machine here https://github.com/fabianpatras/vmm. It can be a good inspiration for the future.
Let me know if you have any other questions. Feel free to close the request if somehow we answered to your question.
We will keep updated/reopen this feature request if something will change in the future 😊

Kind Regards,
Marco

@gedw99
Copy link
Author

gedw99 commented Feb 12, 2024

Hey Marco

yesterday I found a hyper visor lib for Mac. Is used by redhat for Podman . Also by Lima.

So I could work on integrating by I don’t know if the Apple Hypervisor API allows nested virtualisation which Firecracker requires.

@gedw99
Copy link
Author

gedw99 commented Feb 12, 2024

https://discussions.apple.com/thread/255314811?sortBy=best

Looks like no nested virt, but perhaps in M3, but who knows with apple

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

No branches or pull requests

2 participants