{"record":{"id":"002fda4a009ed1ca","repo":"abiosoft/colima","slug":"config-missing-for-colima-profile-s-w","errorCode":null,"errorMessage":"config missing for colima profile '%s': %w","messagePattern":"config missing for colima profile '(.+?)': %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/clone.go","lineNumber":58,"sourceCode":"\t\t\t\treturn fmt.Errorf(\"error preparing to copy VM: %w\", err)\n\t\t\t}\n\n\t\t\tif err := cli.Command(\"cp\",\n\t\t\t\tfilepath.Join(from.LimaInstanceDir(), \"basedisk\"),\n\t\t\t\tfilepath.Join(from.LimaInstanceDir(), \"diffdisk\"),\n\t\t\t\tfilepath.Join(from.LimaInstanceDir(), \"cidata.iso\"),\n\t\t\t\tfilepath.Join(from.LimaInstanceDir(), \"lima.yaml\"),\n\t\t\t\tto.LimaInstanceDir(),\n\t\t\t).Run(); err != nil {\n\t\t\t\treturn fmt.Errorf(\"error copying VM: %w\", err)\n\t\t\t}\n\t\t}\n\n\t\t{\n\t\t\tlogrus.Info(\"copying config...\")\n\t\t\t// verify source config exists\n\t\t\tif _, err := os.Stat(from.LimaInstanceDir()); err != nil {\n\t\t\t\treturn fmt.Errorf(\"config missing for colima profile '%s': %w\", from.ShortName, err)\n\t\t\t}\n\n\t\t\t// ensure destination config directory\n\t\t\tif err := cli.Command(\"mkdir\", \"-p\", filepath.Dir(to.LimaInstanceDir())).Run(); err != nil {\n\t\t\t\treturn fmt.Errorf(\"cannot copy config to new profile '%s': %w\", to.ShortName, err)\n\t\t\t}\n\n\t\t\tif err := cli.Command(\"cp\", from.LimaInstanceDir(), to.LimaInstanceDir()).Run(); err != nil {\n\t\t\t\treturn fmt.Errorf(\"error copying VM config: %w\", err)\n\t\t\t}\n\t\t}\n\n\t\tlogrus.Info(\"clone successful\")\n\t\tlogrus.Infof(\"run `colima start %s` to start the newly cloned profile\", to.ShortName)\n\t\treturn nil\n\t},\n}\n","sourceCodeStart":40,"sourceCodeEnd":76,"githubUrl":"https://github.com/abiosoft/colima/blob/c3a5f9184d83a197184f897a9f07eb3c01b3bc88/cmd/clone.go#L40-L76","documentation":"Returned by `colima clone` (cmd/clone.go:58) during the 'copying config' phase when a second os.Stat on the source Lima instance directory fails. The same directory passed the initial existence check, so this fires only if it disappeared or became unreadable between the two checks.","triggerScenarios":"Concurrent removal of the source profile (a parallel `colima delete` or `limactl delete`), or a permission/IO error surfacing on the second stat (e.g. ACL change mid-clone).","commonSituations":"Running two colima commands against the same profile simultaneously; automation scripts racing cleanup jobs against clones.","solutions":["Ensure no other colima/limactl operation touches the source profile during the clone, then retry","Verify the directory still exists: `ls -ld ~/.colima/_lima/<src-profile>`","If the source was deleted, recreate it with `colima start -p <src>` before cloning again"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Serialize profile operations: hold a lock or simply verify presence right before the call\nif _, err := os.Stat(from.LimaInstanceDir()); err != nil {\n    return fmt.Errorf(\"source profile vanished; concurrent colima operation detected: %w\", err)\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never run two colima/limactl commands against the same profile concurrently","In automation, serialize clone/delete/start per profile (flock or job queue)","Re-clone after fixing the source profile if this race triggers"],"tags":["clone","race","filesystem","colima"],"backgroundTag":null,"analyzedSha":"c3a5f9184d83a197184f897a9f07eb3c01b3bc88","analyzedAt":"2026-08-15T18:58:08.334Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}