utmapp / UTM

Virtual machines for iOS and macOS
https://getutm.app
Apache License 2.0
26.58k stars 1.33k forks source link

[FEATURE REQUEST] Boot secondary, physically installed OS as a VM #5051

Open Rastafabisch opened 1 year ago

Rastafabisch commented 1 year ago

It would be a great addition if UTM could boot other, physically on the Mac installed OS. This could be other versions of macOS as well as Windows or Linux. Parallels Desktop as well as VMWare provide this functionality, at least for Bootcamp.

This would be a great feature on Intel Mac and a stand out feature on apple silicon (for Asahi based installs).

ktprograms commented 1 year ago

Unfortunately because UTM is a sandboxed app, it can't access physical partitions.

You can use nbd (via qemu-nbd) to serve the partition as a block device to a Linux VM, and/or you might be able to host a network boot server to be able to boot from that partition, but I've never tried this.

Hmm @osy is the utmctl command also sandboxed, and if not, could functionality to host a network boot server be implemented eventually?

osy commented 1 year ago

Yes, utmctl is still sandboxed

ktprograms commented 1 year ago

Huh, that's unfortunate. Thanks for confirming

martin-braun commented 1 year ago

Oh what a bummer. Sometimes native performance is needed on a VM, for instance BOOTCAMP when gaming. Having the option to boot or virtualize from the same partition is the absolute killer feature of Parallels. I'd love to see UTM going in that direction.

@ktprograms Could a Helper Tool with higher privileges not bridge a real partition to UTM? Something like this:

image

Which would only be necessary to mount partitions into a VM and would stay optional for the general user who just wants to use VMs the normal way.

ktprograms commented 1 year ago

@martin-braun serving a block device doesn't need higher privileges AFAIK, just that it needs to be unsandboxed, which UTM can't do as it is on the App Store.

You can already do this with qemu-nbd currently, so I don't see a need for a custom UTM helper if it can't be bundled in the main UTM.app anyway.

XavierBestelSonos commented 1 week ago

I would gladly have an un-sandboxed UTM app for this purpose.