The cluster DNS works, but CoreDNS CPU is pegged and logs show thousands of queries per second for names like `metadata.google.internal.svc.cluster.local`.
IntermediateTroubleshootingServices, DNS, Ingress and NetworkPolicy
Answer
Likely causes → A chatty client (SDK probing a metadata endpoint, a service resolving on every request without caching) multiplied by ndots:5 search expansion; CoreDNS has too few replicas and cache is small.
Diagnose →
kubectl -n kube-system edit configmap coredns # add 'log' temporarily
kubectl logs -n kube-system -l k8s-app=kube-dns | awk '{print $NF}' | sort | uniq -c | sort -rn | head
kubectl top pods -n kube-system -l k8s-app=kube-dns
Fix → Find the client and fix its caching or name; scale CoreDNS (cluster-proportional-autoscaler), raise cache 30, deploy NodeLocal DNSCache. Remove the log plugin afterwards.
Prevent → Monitor coredns_dns_requests_total by type and response code; NXDOMAIN rates reveal ndots abuse.
More on Services, DNS, Ingress and NetworkPolicy
`curl http://orders.shop.svc.cluster.local` hangs, and `kubectl get endpointslices -l kubernetes.io/service-name=orders` shows `ENDPOINTS <unset>`.BeginnerEndpoints exist, but `curl orders:80` returns `Connection refused`.BeginnerA Service works when you curl the Pod IP but times out on the ClusterIP from every node.IntermediateInside a Pod, `nslookup orders` returns `;; connection timed out; no servers could be reached`.BeginnerCoreDNS Pods are in CrashLoopBackOff with `[FATAL] plugin/loop: Loop (127.0.0.1:41823 -> :53) detected for zone "."`.IntermediateCalls to `api.stripe.com` from Pods are slow, and CoreDNS logs show `api.stripe.com.payments.svc.cluster.local`, `api.stripe.com.svc.cluster.local` … all `NXDOMAIN`.Intermediate