DNS resolves names to records such as IP addresses. Reaching the destination also requires a route, permission for the traffic, and a service listening on the expected port.
Private DNS and resolver views
With split-horizon DNS, a name can resolve differently inside and outside a private network. A private resolver might return an internal address while a public resolver returns a different address or no record.
Query from the affected workload or use its resolver. An answer from your laptop can describe a different network.
TTL and cached answers
A record’s time to live (TTL) tells resolvers how long they can normally reuse a cached answer. After an address changes, clients can still receive the old answer while earlier cache entries expire. Lower the TTL ahead of a planned change to shorten that window.
From a DNS answer to a working connection
The operating system’s routing table determines the path to a resolved address. Check the DNS answer and the route from the affected environment, then test the destination port. A successful TCP connection confirms transport to that address and port. Check TLS and the application response separately.
DNS inside Kubernetes
Cluster DNS lets workloads look up Services by name. For a normal ClusterIP Service, DNS returns the Service’s virtual IP. A Pod can reach that IP directly while name lookups fail if its queries cannot reach the cluster DNS service.
Allowing DNS through egress policy
An egress NetworkPolicy controls outbound traffic from the Pods it selects when the cluster’s networking plugin enforces it. With default-deny egress, allow the required DNS destination and both UDP and TCP on port 53. Use the cluster’s actual DNS path and scope the exception to that dependency.