k8s-pod-health-investigator

Diagnose unhealthy Kubernetes pods using kubectl status, logs, events, and rollout history.

Updated Apr 5, 2026
One-click install
npx skills add https://github.com/schoolofdevops/401 --skill k8s-pod-health-investigator-schoolofdevops
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: k8s-pod-health-investigator
Source: https://github.com/schoolofdevops/401/tree/main/Course%20-%20Agentic%20Devops/paradigm-comparison/hermes-version
Command: npx skills add https://github.com/schoolofdevops/401 --skill k8s-pod-health-investigator-schoolofdevops

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When pods enter CrashLoopBackOff, ImagePullBackOff, or OOMKilled states, on-call engineers must manually correlate pod status, logs, events, and deployment history to find the root cause. This Skill automates that investigation workflow and produces a structured diagnosis report with severity classification and remediation recommendations. ## Core Features & Use Cases - Systematic Cluster State Collection: Gathers pod status, container logs (including previous crashed instances), warning events, and deployment rollout history via kubectl. - Decision-Tree Diagnosis: Classifies failures by reason code (CrashLoopBackOff, ImagePullBackOff, OOMKilled, high restart counts, stuck rollouts) and maps evidence to root causes. - Safe Remediation Guidance: Recommends specific kubectl actions such as rollout undo or memory limit increases, with strict escalation rules requiring human approval for any mutation. - Use Case: An on-call alert fires for a pod in CrashLoopBackOff. Provide the namespace, and the Skill collects evidence, identifies an OOM kill from exit code 137 in the logs, and recommends increasing memory limits pending approval. ## Quick Start Investigate the unhealthy pods in the payments namespace and tell me the root cause with recommended fixes.

Frequently Asked Questions about k8s-pod-health-investigator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I diagnose a pod stuck in CrashLoopBackOff?

Run kubectl describe pod to check events, then pull logs with kubectl logs --previous to see the crashed container's output. This Skill automates that sequence and classifies the cause as OOM kill, dependency connection failure, or application error based on log evidence.

How to find the root cause of ImagePullBackOff in Kubernetes?

Check the pod's events with kubectl describe pod for messages like 'repository does not exist' or 'unauthorized'. A missing image tag indicates a typo in the deployment spec, while authentication errors point to missing or expired imagePullSecrets.

What does OOMKilled mean and how do I fix it?

OOMKilled means the container exceeded its memory limit and was terminated by the kernel, typically showing exit code 137 in logs. The fix is increasing the container's memory limits in the deployment spec, which this Skill recommends but never applies without human approval.

Can this Skill restart or delete pods automatically?

No. The Skill is read-only by design and never executes kubectl delete, drain, cordon, apply, or patch without explicit human approval. It only collects diagnostic data and proposes remediation commands for review.

When should pod issues be escalated instead of self-healed?

Escalate when OOMKilled appears across multiple namespaces, a node shows NotReady status, or the root cause lies outside Kubernetes such as an application bug or external database failure. These conditions exceed pod-level remediation authority.