kubernetes networking ai_generated true

endpoints for service not found

ID: kubernetes/service-has-no-endpoints

Also available as: JSON · Markdown
93%Fix Rate
95%Confidence
50Evidence
2023-01-01First Seen

Version Compatibility

VersionStatusIntroducedDeprecatedNotes
8 active

Root Cause

Service has no matching pods — selector doesn't match any pod labels, or pods aren't ready.

generic

Workarounds

  1. 95% success Verify selectors match: kubectl get pods --selector=app=myapp
    Service selector must match pod labels exactly

    Sources: https://kubernetes.io/docs/concepts/services-networking/service/

  2. 90% success Check if pods are Ready: kubectl get pods -o wide — unready pods aren't added to endpoints
    Pods must pass readiness probes to receive traffic

Dead Ends

Common approaches that don't work:

  1. Removing the selector from the Service 85% fail

    Creates a Service with no backends; all requests fail

  2. Adding a manual Endpoints resource 60% fail

    Fragile; must be manually updated when pods change

Error Chain

Frequently confused with: