HeadlinesBriefing favicon HeadlinesBriefing.com

Bypassing Apple's 2 VM Limit on Apple Silicon

Hacker News •
×

Developers utilizing Apple Silicon systems frequently hit a frustrating wall: Apple's Virtualization framework officially caps active macOS guest VMs at two, dictated by the macOS Software License Agreement. This restriction becomes problematic for consultants and dedicated testers needing parallel environments. The initial search for this limit within userspace frameworks like Virtualization.framework proved fruitless, pushing the investigation deeper into the operating system core.

Investigation shifted to the kernel, XNU, where the check resides in closed-source hypervisor components. By comparing Intel and Apple Silicon kernel binaries, the source located the VM quota management using the `hv_apple_isa_vm_quota` variable. In development kernels, this limit is adjustable via a boot-arg, offering a clear path around the restriction for researchers.

For release kernels, Apple ties the quota override to System Integrity Protection (`CSR_ALLOW_APPLE_INTERNAL`), effectively locking the feature down. The practical workaround detailed involves building a custom development kernel collection using the Kernel Debug Kit (KDK) matching the host OS build, like Sonoma Beta 4 23A5301h.

To implement the change, users must disable SIP and configure custom boot arguments (`kcsuffix=development`, `hypervisor=0x1`, and setting `hv_apple_isa_vm_quota=0xFF`) in recovery mode. This technical maneuver successfully overrides the default two-VM ceiling, allowing up to 255 active VMs for development purposes on the M2 Pro MacBook Pro.