Back to all scenarios
Scenario #162
Networking
K8s v1.19, Google GKE

DNS Resolution Failures Due to Misconfigured CoreDNS

DNS resolution failures due to misconfigured CoreDNS, leading to application errors.

Find this helpful?
What Happened

CoreDNS was misconfigured with the wrong upstream DNS resolver, causing DNS lookups to fail and leading to application connectivity issues.

Diagnosis Steps
  • 1Ran kubectl logs -l k8s-app=coredns to view the CoreDNS logs and identified errors related to upstream DNS resolution.
  • 2Used kubectl get configmap coredns -n kube-system -o yaml to inspect the CoreDNS configuration.
Root Cause

CoreDNS was configured with an invalid upstream DNS server that was unreachable.

Fix/Workaround
• Updated CoreDNS ConfigMap to point to a valid upstream DNS server.
• Restarted CoreDNS pods to apply the new configuration.
Lessons Learned

Double-check DNS configurations during deployment and monitor CoreDNS health regularly.

How to Avoid
  • 1Automate the validation of DNS configurations and use reliable upstream DNS servers.
  • 2Set up monitoring for DNS resolution latency and errors.