Difficulty: Beginner
What are the possible phases of a Pod, and how do they relate to the STATUS values like CrashLoopBackOff that you see in kubectl?
A Pod's status.phase has exactly five values: Pending, Running, Succeeded, Failed and Unknown. The phase is a high-level summary; the detail lives in each container's state (Waiting, Running, Terminated) and in Pod conditions such as Ready. Values like CrashLoopBackOff, ContainerCreating or Terminating that appear in kubectl get pods are reasons or derived statuses, not phases.
| Phase | Meaning | Common causes |
|---|---|---|
Pending | Accepted by the API server, but one or more containers are not running yet | Waiting for scheduling, pulling images, mounting volumes |
Running | Bound to a node, all containers created, at least one running or restarting | Normal state for services |
Succeeded | All containers exited with code 0 and will not restart | Completed Job Pods |
Failed | All containers terminated and at least one failed (non-zero or killed by the system) | Job with restartPolicy: Never that crashed, evicted Pods |
Unknown | The control plane cannot get the Pod's state | Node lost contact with the API server |
A Pod reaches Succeeded or Failed only when its containers will not be restarted. With the default restartPolicy: Always (used by Deployments), a crashing container keeps being restarted, so the phase stays Running even though the app is broken.
Each container is in one of three states:
Waiting, with a reason such as ContainerCreating, ImagePullBackOff, ErrImagePull, CreateContainerConfigError or CrashLoopBackOff.Running.Terminated, with an exit code and a reason such as Completed, Error or OOMKilled.kubectl get pods shows the most useful reason in the STATUS column. So CrashLoopBackOff means "the container keeps exiting and the kubelet is waiting an increasing back-off (up to 5 minutes) before restarting it", while the phase is still Running. Terminating means the Pod has a deletionTimestamp and is shutting down gracefully.
Conditions answer more specific yes/no questions:
PodScheduled: assigned to a node.PodReadyToStartContainers: sandbox and networking are ready (newer clusters).Initialized: all init containers completed.ContainersReady: all containers pass readiness.Ready: the Pod can receive Service traffic.A Pod can be Running but not Ready, for example when its readiness probe fails. It stays out of Service endpoints until it recovers.
Pending for a long time: kubectl describe pod and look for FailedScheduling (not enough CPU/memory, taints, affinity) or image pull errors.CrashLoopBackOff: kubectl logs <pod> --previous to see why it died.OOMKilled (exit 137): raise the memory limit or fix the leak.Unknown: check the node with kubectl get nodes and kubectl describe node.# Phase only (never shows CrashLoopBackOff)
kubectl get pod api-6f7c9 -o jsonpath='{.status.phase}'
# Running
# Why the container is unhappy
kubectl get pod api-6f7c9 \
-o jsonpath='{.status.containerStatuses[0].state}'
# {"waiting":{"reason":"CrashLoopBackOff",...}}
# Last crash exit code
kubectl get pod api-6f7c9 \
-o jsonpath='{.status.containerStatuses[0].lastState.terminated.exitCode}'
# Pods by phase across the cluster
kubectl get pods -A --field-selector status.phase=Failed
The phase says Running while the container state reveals CrashLoopBackOff, which is exactly the distinction interviewers probe.
Pod Phase, Container States, Pod Conditions, CrashLoopBackOff, Restart Policy