ERVFAIL
kubernetes
dns_error
ai_generated
true
CoreDNS: SERVFAIL for cluster.local, dial tcp: lookup on: no such host
ID: kubernetes/k8s-dns-resolution-failed
85%Fix Rate
87%Confidence
60Evidence
2023-01-01First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| 8 | active | — | — | — |
Root Cause
DNS resolution fails at the cluster level because CoreDNS is down, misconfigured, or blocked by NetworkPolicy.
genericWorkarounds
-
92% success Check CoreDNS pod status and logs: kubectl get pods -n kube-system -l k8s-app=kube-dns
kubectl logs -n kube-system -l k8s-app=kube-dns — look for upstream DNS failures or loop detection
Sources: https://kubernetes.io/docs/tasks/administer-cluster/dns-debugging-resolution/
-
85% success Check if NetworkPolicy blocks egress to kube-dns on port 53
Ensure egress NetworkPolicy allows UDP/TCP port 53 to kube-system namespace
Sources: https://kubernetes.io/docs/tasks/administer-cluster/dns-debugging-resolution/
Dead Ends
Common approaches that don't work:
-
Add custom /etc/hosts entries to all pods
85% fail
Doesn't scale — service IPs change and new services won't be resolvable
-
Restart all pods in the cluster
80% fail
If CoreDNS is the problem, restarting app pods won't fix DNS
Error Chain
Leads to:
Preceded by:
Frequently confused with: