Explain the Kubernetes Pod Lifecycle Phases
A Pod progresses through five phases: Pending (waiting to be scheduled), Running (at least one container is running), Succeeded (all containers exited with code 0), Failed (at least one container exited with a non-zero code), and Unknown (Pod status cannot be determined).
Detailed Answer
Every Pod in Kubernetes has a status.phase field that reflects its current lifecycle phase. Understanding these phases is essential for debugging and monitoring.
The Five Pod Phases
| Phase | Meaning | |-------|---------| | Pending | Pod accepted by the cluster but one or more containers aren't running yet. Includes scheduling time and image pulls. | | Running | Pod bound to a node and at least one container is running or starting/restarting. | | Succeeded | All containers terminated successfully (exit code 0) and won't be restarted. | | Failed | All containers terminated, and at least one exited with a non-zero code. | | Unknown | Pod state can't be determined — usually a node communication issue. |
Debugging by Phase
# Check Pod phase
kubectl get pod my-pod -o jsonpath='{.status.phase}'
# Get detailed conditions and container statuses
kubectl describe pod my-pod
# Check events for scheduling issues (Pending Pods)
kubectl get events --field-selector involvedObject.name=my-pod
Container States vs Pod Phases
Don't confuse Pod phases with container states. A Pod in Running phase can have containers in Waiting (e.g., CrashLoopBackOff), Running, or Terminated states. Always check container-level status when debugging.
Why Interviewers Ask This
This question tests whether you understand how Kubernetes manages workload state. Knowing the lifecycle phases is critical for debugging stuck or failed Pods.
Common Follow-Up Questions
Key Takeaways
- The five phases are Pending, Running, Succeeded, Failed, and Unknown.
- A Pod in Running phase doesn't mean the app is healthy — check readiness probes.
- Pending usually means a scheduling or resource issue.
- CrashLoopBackOff is not a phase — it's a container restart state within the Running phase.