MidTroubleshooting

The deploy reports success, pods are Running, but users get 502s. Where do you look?

What they are really testing: Whether you can reason about the path between the user and the container. Running is not ready, and 502 specifically means the proxy could not get a usable response from upstream.

A real interview question

The deploy reports success, pods are Running, but users get 502s. Where do you look?

What most people say

drag me

I would check the application logs for errors.

Reasonable but incomplete, and often empty here: if traffic never reaches the container, the app logs nothing at all. The candidate needs to reason about the routing path, not just the application.

The follow-ups they ask next

  • Endpoints are populated and port-forward works. What is left?

    The ingress controller or its config: wrong service name or port in the ingress, TLS mismatch, or an upstream timeout shorter than the app response time. Check controller logs.

  • Why would a 504 point somewhere different from a 502?

    504 is a timeout, so upstream was reachable but too slow, pointing at application performance or a dependency. 502 is a bad or absent response, pointing at connectivity or the app failing immediately.

What the interviewer is listening for

  • Interprets the status code as a clue
  • Checks endpoints early
  • Uses port-forward to bisect the path

What sinks the answer

  • Only reads app logs
  • Treats Running as Ready
  • No systematic path narrowing

If you genuinely do not know

Say this instead of freezing. Reasoning out loud from what you do know beats silence every single time, and a good interviewer is listening for exactly that.

502 means [a proxy reached my service but got no usable response], so I go outside in: [readiness, not just Running], then [the endpoints object, empty means selector mismatch or failing readiness], then [port and bind address mismatch], then [port-forward to a pod and curl to split routing from app].

Keep going with troubleshooting

All 87 devops engineer questions

Knowing the answer is not the same as recalling it under pressure

Sign in to send the questions you fumble to spaced recall, so they come back right before you would forget them, and learn the concepts behind them with hands-on labs.

Start free