Kubernetes Service Not Reachable

Systematically debug Kubernetes Service connectivity failures using endpoints, selectors, and DNS.

Overview

Overview

'Service not reachable' covers many failure modes with one user-visible symptom: connection refused or connection timeout when calling a Service. The root causes and fixes differ widely, so a layered diagnosis beats random investigation.

The layers are the hops a call takes on its way from the client to a process. Any one of them can drop it, so it helps to see them in order.

Key concepts

  • Endpoints
  • kube-proxy
  • Selector
  • NetworkPolicy
  • ClusterIP

Interview questions

  • Walk through the complete diagnostic sequence for a Kubernetes Service returning connection refused.
  • How does a NetworkPolicy affect Service routing and what is the default behavior when policies exist?
  • What are the most common selector mismatch patterns that cause empty Kubernetes Service endpoints?

Sign up free to read the full topic

More Troubleshooting topics

Start free on Cariara · Coding problems · System design studio