{"record":{"id":"622935c95ab8d7fc","repo":"lima-vm/lima","slug":"krunkit-cli-not-found-in-path-install-it-via-bre","errorCode":null,"errorMessage":"krunkit CLI not found in PATH. Install it via:\nbrew tap slp/krun\nbrew install krunkit","messagePattern":"krunkit CLI not found in PATH\\. Install it via:\nbrew tap slp/krun\nbrew install krunkit","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/driver/krunkit/krunkit_driver_darwin_arm64.go","lineNumber":227,"sourceCode":"\treturn nil\n}\n\nfunc validateConfig(cfg *limatype.LimaYAML) error {\n\tif cfg == nil {\n\t\treturn errors.New(\"configuration is nil\")\n\t}\n\tmacOSProductVersion, err := osutil.ProductVersion()\n\tif err != nil {\n\t\treturn err\n\t}\n\tif macOSProductVersion.LessThan(*semver.New(\"13.0.0\")) {\n\t\treturn errors.New(\"krunkit driver requires macOS 13 or higher to run\")\n\t}\n\tif cfg.Arch != nil && !limatype.IsNativeArch(*cfg.Arch) {\n\t\treturn fmt.Errorf(\"unsupported arch: %#q (krunkit requires native arch)\", *cfg.Arch)\n\t}\n\tif _, err := exec.LookPath(vmType); err != nil {\n\t\treturn errors.New(\"krunkit CLI not found in PATH. Install it via:\\nbrew tap slp/krun\\nbrew install krunkit\")\n\t}\n\t// Also check if krunkit version >= 1.2.1 because of the vsock forwarder feature\n\tif err := checkKrunkitVersion(); err != nil {\n\t\treturn err\n\t}\n\n\tif cfg.MountType != nil && (*cfg.MountType != limatype.VIRTIOFS && *cfg.MountType != limatype.REVSSHFS) {\n\t\treturn fmt.Errorf(\"field `mountType` must be %#q or %#q for krunkit driver, got %#q\", limatype.VIRTIOFS, limatype.REVSSHFS, *cfg.MountType)\n\t}\n\n\tif cfg.TPM != nil && *cfg.TPM {\n\t\treturn errors.New(\"field `tpm` is not supported in krunkit driver\")\n\t}\n\n\tif cfg.NestedVirtualization != nil && *cfg.NestedVirtualization {\n\t\tif macOSProductVersion.LessThan(*semver.New(\"15.0.0\")) {\n\t\t\treturn errors.New(\"nested virtualization requires macOS 15 or newer\")\n\t\t}","sourceCodeStart":209,"sourceCodeEnd":245,"githubUrl":"https://github.com/lima-vm/lima/blob/dd909d0973cd84fa35f9e1693181b4585ea616c1/pkg/driver/krunkit/krunkit_driver_darwin_arm64.go#L209-L245","documentation":"The krunkit driver requires the `krunkit` CLI binary to launch libkrun VMs on macOS. During config validation (validateConfig, invoked by Validate and fillConfig), Lima runs exec.LookPath(vmType) to confirm the binary is on PATH; if it is missing, validation aborts with install instructions because no VM can be started without it.","triggerScenarios":"Calling limactl validate or limactl start on a config whose vmType is krunkit on macOS while `krunkit` is not installed or not in any PATH directory.","commonSituations":"Fresh macOS machines where krunkit was never installed; Homebrew-installed binary not linked into PATH; using a Lima config copied from another machine; PATH stripped in non-interactive shells/CI.","solutions":["Install krunkit: `brew tap slp/krun && brew install krunkit`","Verify it is resolvable: `which krunkit`; if installed elsewhere, add its directory to PATH","If krunkit is not needed, switch the instance config to vmType qemu or vz"],"exampleFix":"// before (lima.yaml)\nvmType: krunkit\n// after (if krunkit is intentionally not installed)\nvmType: qemu","handlingStrategy":"validation","validationCode":"if _, err := exec.LookPath(\"krunkit\"); err != nil {\n    return fmt.Errorf(\"krunkit not installed; run: brew tap slp/krun && brew install krunkit\")\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Install krunkit before switching vmType to krunkit","Run `which krunkit` in the same shell/CI environment that runs limactl","Pin the toolchain in setup scripts so PATH includes brew prefixes"],"tags":["macos","krunkit","missing-binary","path"],"backgroundTag":"missing-cli-binary-on-path","analyzedSha":"dd909d0973cd84fa35f9e1693181b4585ea616c1","analyzedAt":"2026-09-01T14:24:59.842Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}