CrashLoopBackOff
The container starts, exits, and Kubernetes waits longer between each restart.
The process inside the container is crashing. The reason is almost always in the previous container log, not in the CrashLoopBackOff line itself.
Commands to start with
- kubectl logs POD -c CONTAINER --previous
- kubectl describe pod POD
Explain a CrashLoopBackOff paste
Output
The result shows up here. Your input is not written to the log.
Questions
›Is CrashLoopBackOff the root cause?
No. It means the kubelet has given up restarting immediately. Read the previous logs for the actual error.
›What if the logs are empty?
The process may be exiting before it writes anything. Check the command, args, and whether a required file or env var is missing.