{"record":{"id":"2b658924ff30611f","repo":"abiosoft/colima","slug":"daemon-is-not-running","errorCode":null,"errorMessage":"daemon is not running","messagePattern":"daemon is not running","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"environment/vm/lima/daemon.go","lineNumber":94,"sourceCode":"\t\t})\n\t}\n\n\t// start daemon\n\ta.Add(func() error {\n\t\treturn l.daemon.Start(ctx, conf)\n\t})\n\n\tstatusKey := struct{ key string }{key: \"daemonStatus\"}\n\t// delay to ensure that the processes have started\n\tif conf.Network.Address || conf.MountINotify {\n\t\ta.Retry(\"\", time.Second*1, 15, func(i int) error {\n\t\t\ts, err := l.daemon.Running(ctx, conf)\n\t\t\tctx = context.WithValue(ctx, statusKey, s)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif !s.Running {\n\t\t\t\treturn fmt.Errorf(\"daemon is not running\")\n\t\t\t}\n\t\t\tfor _, p := range s.Processes {\n\t\t\t\tif !p.Running {\n\t\t\t\t\treturn p.Error\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn nil\n\t\t})\n\t}\n\n\t// network failure is not fatal\n\tif err := a.Exec(); err != nil {\n\t\tif useVmnet {\n\t\t\tfunc() {\n\t\t\t\tinstalled, _ := ctx.Value(networkInstalledKey).(bool)\n\t\t\t\tif !installed {\n\t\t\t\t\tlog.Warnln(fmt.Errorf(\"error setting up network dependencies: %w\", err))\n\t\t\t\t\treturn","sourceCodeStart":76,"sourceCodeEnd":112,"githubUrl":"https://github.com/abiosoft/colima/blob/c3a5f9184d83a197184f897a9f07eb3c01b3bc88/environment/vm/lima/daemon.go#L76-L112","documentation":"Emitted inside an a.Retry('', 1s, 15) loop that polls l.daemon.Running(ctx, conf) after starting the VM daemon processes (network and/or inotify): after up to 15 checks the daemon Status still reports s.Running == false. The daemon (colima's root-level helper inside the Lima VM) failed to come up, so start aborts with this error (or a per-process error from status.Processes if a specific child died).","triggerScenarios":"'colima start' with --network-address/vmnet networks or --mount-inotify where the in-VM daemon binary fails to launch: guest out of memory (daemon OOM-killed), the daemon socket/status file unreadable, sudo/launch of the daemon blocked, or the VM still busy (all 15s of retries exhausted on very slow machines); a previous crash left a stale status file claiming not-running while the process is defunct.","commonSituations":"Low-memory VMs (default 2GiB) with kubernetes plus inotify enabled; VMs recovering from host sleep; first start after a colima upgrade where the daemon binary layout changed but the VM was resumed from an old state; heavily loaded CI runners where the 15×1s window is too short.","solutions":["Give the VM more resources and retry: 'colima stop && colima start --memory 4 --cpu 2' (adjust as needed).","Inspect the daemon inside the guest: 'colima ssh -- ps aux | grep colima-daemon' and check its log/socket under /var/lib/colima (or the profile's daemon dir) for the real launch error.","If a stale daemon is suspected, fully stop and start (not resume) — 'colima stop -f && colima start' — so the daemon is re-spawned cleanly.","Recreate the VM to get a fresh daemon install after a colima version change: 'colima delete -f && colima start'.","Report upstream with 'colima daemon' logs if it persists on a fresh VM with defaults (no --network-address, no --mount-inotify)."],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// preflight: VM must be running and responsive before daemon-dependent steps\nif !l.Running(ctx) {\n    return fmt.Errorf(\"VM not running; cannot verify daemon status\")\n}","typeGuard":null,"tryCatchPattern":"// the code already retries 15x1s; on failure inspect per-process errors\ns, err := l.daemon.Running(ctx, conf)\nif err != nil {\n    return err\n}\nif !s.Running {\n    for _, p := range s.Processes {\n        if !p.Running {\n            return fmt.Errorf(\"daemon process %s failed: %v\", p.Name, p.Error)\n        }\n    }\n    return fmt.Errorf(\"daemon is not running\")\n}","preventionTips":["Give the VM adequate memory/cpu when enabling --network-address or --mount-inotify.","Prefer a full 'colima stop && colima start' over resume after host sleep.","After colima upgrades, recreate the VM so the daemon binary version matches."],"tags":["daemon","vm","retry","startup","lima"],"backgroundTag":null,"analyzedSha":"c3a5f9184d83a197184f897a9f07eb3c01b3bc88","analyzedAt":"2026-08-15T18:58:08.334Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}