{"record":{"id":"fd5528d7e1d4c81d","repo":"cilium/cilium","slug":"status-check-failed-s","errorCode":null,"errorMessage":"status check failed: [%s]","messagePattern":"status check failed: \\[(.+?)\\]","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cilium-cli/cli/status.go","lineNumber":58,"sourceCode":"\t\t\t}\n\t\t\tif params.Output == status.OutputJSON {\n\t\t\t\tjsonStatus, err := json.MarshalIndent(s, \"\", \" \")\n\t\t\t\tif err != nil {\n\t\t\t\t\t// Report the most recent status even if an error occurred.\n\t\t\t\t\tfmt.Fprint(os.Stderr, s.Format())\n\t\t\t\t\tfatalf(\"Unable to marshal status to JSON:  %s\", err)\n\t\t\t\t}\n\t\t\t\tfmt.Println(string(jsonStatus))\n\t\t\t} else {\n\t\t\t\tfmt.Print(s.Format())\n\t\t\t}\n\n\t\t\tif len(s.CollectionErrors) > 0 {\n\t\t\t\terrs := make([]string, 0, len(s.CollectionErrors))\n\t\t\t\tfor _, e := range s.CollectionErrors {\n\t\t\t\t\terrs = append(errs, e.Error())\n\t\t\t\t}\n\t\t\t\terr = fmt.Errorf(\"status check failed: [%s]\", strings.Join(errs, \", \"))\n\t\t\t}\n\t\t\treturn err\n\t\t},\n\t}\n\tcmd.Flags().BoolVar(&params.Wait, \"wait\", false, \"Wait for status to report success (no errors and warnings)\")\n\tcmd.Flags().DurationVar(&params.WaitDuration, \"wait-duration\", defaults.StatusWaitDuration, \"Maximum time to wait for status\")\n\tcmd.Flags().BoolVar(&params.IgnoreWarnings, \"ignore-warnings\", false, \"Ignore warnings when waiting for status to report success\")\n\tcmd.Flags().IntVar(&params.WorkerCount,\n\t\t\"worker-count\", status.DefaultWorkerCount,\n\t\t\"The number of workers to use\")\n\tcmd.Flags().StringVarP(&params.Output, \"output\", \"o\", status.OutputSummary, \"Output format. One of: json, summary\")\n\tcmd.Flags().BoolVar(&params.Interactive, \"interactive\", true, \"Refresh the status summary output after each retry when --wait flag is specified\")\n\tcmd.Flags().BoolVar(&params.Verbose, \"verbose\", false, \"Print more verbose error / log messages\")\n\n\treturn cmd\n}\n","sourceCodeStart":40,"sourceCodeEnd":75,"githubUrl":"https://github.com/cilium/cilium/blob/ac7b90affa4baf0642e6685319d56907b3a73a6d/cilium-cli/cli/status.go#L40-L75","documentation":"cilium-cli's status command aggregates errors collected while checking node/agent/controller status. If any CollectionErrors accumulated during the run, it joins them into a single 'status check failed: [...]' error listing each underlying failure.","triggerScenarios":"Running `cilium status` (or the status subcommand) where one or more collection probes failed: agent not ready on some node, kube-proxy issues, controllers unhealthy, or the k8s client failing to reach pods during the wait window.","commonSituations":"Partially rolled-out Cilium DaemonSet leaving some nodes without healthy agents; CrashLooping cilium pods; CNI wiring problems after install/upgrade; wrong kubeconfig context pointing at a cluster without Cilium.","solutions":["Read the joined sub-errors in brackets and address each (usually unhealthy cilium pods on specific nodes)","Check `kubectl -n kube-system get pods -l k8s-app=cilium` for failing pods and inspect logs","Increase --wait-duration if the check raced with a rollout","Verify you're pointed at the intended cluster/context and Cilium was installed in the expected namespace"],"exampleFix":"// before\ncilium status --wait\n// after\ncilium status --wait --wait-duration 5m\n# then: kubectl -n kube-system logs -l k8s-app=cilium --tail=100","handlingStrategy":"try-catch","validationCode":"// before running: confirm cilium pods are healthy\n// kubectl -n kube-system get pods -l k8s-app=cilium","typeGuard":null,"tryCatchPattern":"if err := cilium.Status(ctx, opts); err != nil {\n\tvar statusErr *fmt.Errorf\n\tif errors.As(err, &statusErr) && strings.HasPrefix(err.Error(), \"status check failed: [\") {\n\t\t// parse the bracketed sub-errors and retry once pods stabilize\n\t}\n}","preventionTips":["Wait for DaemonSet readiness before running status checks","Use --wait-duration sized to your rollout time","Check node health/NotReady nodes proactively","Ensure the kubeconfig context targets the right cluster"],"tags":["kubernetes","health-check","cilium","status","cluster-health"],"backgroundTag":"status-check-failed","analyzedSha":"ac7b90affa4baf0642e6685319d56907b3a73a6d","analyzedAt":"2026-08-31T18:27:15.868Z","schemaVersion":2},"datasetVersion":"2026-08-31T19:17:28.585Z"}