lima-vm/lima · error
nested virtualization requires macOS 15 or newer
Error message
nested virtualization requires macOS 15 or newer
What it means
Nested virtualization under krunkit relies on a macOS feature only present on macOS 15 (Sequoia) and newer. validateConfig checks the detected macOS product version and rejects `nestedVirtualization: true` on older macOS releases.
Source
Thrown at pkg/driver/krunkit/krunkit_driver_darwin_arm64.go:244
if _, err := exec.LookPath(vmType); err != nil {
return errors.New("krunkit CLI not found in PATH. Install it via:\nbrew tap slp/krun\nbrew install krunkit")
}
// Also check if krunkit version >= 1.2.1 because of the vsock forwarder feature
if err := checkKrunkitVersion(); err != nil {
return err
}
if cfg.MountType != nil && (*cfg.MountType != limatype.VIRTIOFS && *cfg.MountType != limatype.REVSSHFS) {
return fmt.Errorf("field `mountType` must be %#q or %#q for krunkit driver, got %#q", limatype.VIRTIOFS, limatype.REVSSHFS, *cfg.MountType)
}
if cfg.TPM != nil && *cfg.TPM {
return errors.New("field `tpm` is not supported in krunkit driver")
}
if cfg.NestedVirtualization != nil && *cfg.NestedVirtualization {
if macOSProductVersion.LessThan(*semver.New("15.0.0")) {
return errors.New("nested virtualization requires macOS 15 or newer")
}
}
if cfg.OS != nil && *cfg.OS == limatype.WINDOWS {
return errors.New("currently Windows guest OS is only supported on QEMU")
}
return nil
}
func isFedoraConfigured(cfg *limatype.LimaYAML) bool {
for _, b := range cfg.Base {
if strings.Contains(strings.ToLower(b.URL), "fedora") {
return true
}
}
for _, img := range cfg.Images {
if strings.Contains(strings.ToLower(img.Location), "fedora") {View on GitHub (pinned to dd909d0973)
Solutions
- Upgrade the host to macOS 15 or newer
- Set `nestedVirtualization: false` or remove the field if nested virt is not required
Example fix
// before (lima.yaml on macOS 14) nestedVirtualization: true // after nestedVirtualization: false
Defensive patterns
Strategy: validation
Validate before calling
if cfg["nestedVirtualization"] == true {
ver, _ := macosProductVersion()
if ver.LessThan(semver.MustParse("15.0.0")) {
return errors.New("nested virtualization needs macOS 15+")
}
} Prevention
- Check `sw_vers -productVersion` before enabling nested virtualization
- Gate krunkit+nested-virt configs to macOS 15+ hosts
- Keep nestedVirtualization false unless needed
When it happens
Trigger: Setting `nestedVirtualization: true` with vmType krunkit on macOS 13 or 14, then running limactl validate or limactl start.
Common situations: Running nested VMs (e.g. VM-in-VM with VZ/krun) requested on an older macOS host; configs authored on a macOS 15 machine deployed to older hosts.
Related errors
- unimplemented by the krunkit driver
- failed to load disk %#q: %w
- failed to run attach disk %#q, in use by instance %#q
- failed to lock disk %#q: %w
- failed to convert extra disk %#q to raw: %w
AI-assisted analysis of lima-vm/lima@dd909d0973 (2026-09-01).
Data as JSON: /api/errors/06db6049c41739f9.
Report an issue: GitHub.