Case

Kubernetes: Ingress returns 404 or 503

Ingress exists but traffic fails. Service ports, endpoints, and ingress controller logs are validated.

Case Summary

  • ProblemIngress URL returns 404/503 even though resources exist.
  • SolutionCheck service selectors/ports, ensure endpoints exist, confirm ingress class and rules, then apply fixes.
  • Toolskubectl get svc/endpoints/ingress · ingress-nginx logs
  • OutcomeIngress routes correctly to the service and the app becomes reachable.

Commands used (examples)

kubectl get pods -n <ns>
kubectl describe pod <pod> -n <ns>
kubectl logs <pod> -n <ns> --previous
kubectl get events -n <ns> --sort-by=.lastTimestamp | tail
systemctl status <service> --no-pager
journalctl -u <service> -n 200 --no-pager