Skip to content
RED SAGSkills
mediumSite Reliability Engineer interview question

A Deployment rollout is stuck because new pods are in CrashLoopBackOff. Walk me through how you would debug it.

What the interviewer wants to hear

  • Limit impact first: pause or roll back the rollout if users are affected
  • Use kubectl describe pod for exit code, reason and events
  • Read logs of the previous container instance
  • Check config, secrets, probes and resource limits that changed
  • Reproduce with the same image and config if needed

Model answer

If users are affected I first make sure old pods are still serving; with maxUnavailable set correctly they are, otherwise I run kubectl rollout undo. Then I run kubectl describe pod on a failing pod and read the last state, exit code and events. Exit code 137 with OOMKilled points to memory limits; exit code 1 usually means the app failed at start-up. Next I run kubectl logs with --previous to see the output of the crashed instance, which often shows a missing environment variable, a bad config value or a failed connection to a dependency. I compare what changed in this release: image, ConfigMaps, Secrets, probes and resources. A liveness probe that is too aggressive can also kill a slow-starting app, so a startup probe may be needed. If it is still unclear, I run the image locally with the same config.

Can you answer it under time pressure?

Take a timed medium round and get scored on every answer.

Start mock interview

More medium Site Reliability Engineer questions