Skip to main content
Troubleshooting DNS can be challenging because it involves multiple systems interacting—from your local machine to the authoritative nameserver—and handling the response on its way back. Understanding the complete flow is essential for diagnosing and resolving issues.
The image illustrates the process of connecting a device to a nameserver using DNS, showing the flow from a home network through various resolvers to authoritative DNS servers on the internet.
Different applications and platforms may implement distinct caching lifecycles. For example, you might execute a DNS command that correctly resolves a domain name:
The image illustrates the concept of caching with icons of a trash bin, gears, and a web interface, highlighting that caching has different lifecycles per application or platform.
Yet, if your browser does not show the expected result, it could be because the operating system caches DNS records for a specified period while the browser uses a separate caching duration. Below is an example using the dig command to query DNS records:
The difference in caching durations between the operating system and the browser can lead to inconsistencies. Below is a quick overview of common DNS issues and initial troubleshooting guidelines:
  1. Communication Issues: Systems may be unable to communicate due to network problems.
  2. Slow DNS: Overloaded resolvers or nameservers can result in slow response times.
  3. Incorrect DNS Responses: Outdated cache records or unsynchronized authoritative nameservers can return wrong responses.
The image lists three basic DNS issues: networking aspects, slow DNS, and wrong DNS responses.
Let’s break down each category and review the appropriate troubleshooting steps. When encountering networking-related DNS problems, begin by checking basic connectivity. Verify that your network interface is configured correctly and determine whether the problem stems from DNS specific issues or overall internet connectivity. First, test connectivity by pinging a reliable public DNS server:
Next, inspect if firewall rules or restrictions are blocking port 53 (UDP or TCP). Use Telnet to verify connectivity:
VPN configurations can lead to DNS issues by introducing conflicts in network routing. Disconnect from the VPN to test if it affects DNS behavior.
The image illustrates a person unplugging a cable from a device, with text suggesting that VPN conflicts can cause DNS leaks or routing issues and advising to check if disconnecting the VPN resolves the issue.

Slow DNS Resolution

Slow DNS responses generally indicate that a server in the resolution chain is overloaded or responding slowly. This may be noticeable when new websites take longer than usual to load. To diagnose slow DNS responses, use the dig command with the +trace option. This command steps through the entire DNS resolution process, exposing the time taken at each phase:
You can also combine the time command with dig to benchmark the resolver’s speed directly. The following example queries Google’s DNS server:
Numerous online tools are available that can benchmark the performance of various DNS resolvers.

Incorrect DNS Responses

Incorrect or inconsistent DNS responses often stem from caching complications or unsynchronized authoritative nameservers. This is a common and challenging DNS issue to diagnose.
The image illustrates two types of DNS issues: caching problems and unsynchronized authoritative nameservers.
Ruijan Paul, an engineer highly regarded for his DNS learning resources, suggests an outward-in approach when diagnosing caching issues. Start from external components, such as public resolvers, and work inward. Even if you clear your local operating system’s cache, stale records may persist if upstream caches continue to provide outdated data. Many public resolvers offer web tools for clearing the DNS cache. For example, major content delivery network providers like Akamai provide mechanisms to invalidate or remove cached entries.
The image is a slide titled "Exploring Cache Tools – Akamai," showing a screenshot of Akamai's tech documentation on purge cache methods, specifically focusing on invalidate and delete methods.
If your system uses an ISP’s resolver, clearing caches on public resolvers like Cloudflare or Google may not produce any changes. In these cases, rebooting or resetting your router might help clear some cached records.
The image illustrates the process of resetting a router when using an ISP resolver, highlighting resolver resets for Windows OS, Linux OS, DNS servers like BIND, and MacOS.

Operating System-Level DNS Troubleshooting

Windows

For Windows users, you can clear and view the DNS cache as well as release and renew your IP configuration using the following commands:

Linux

Modern Linux distributions typically use systemd-resolved for DNS caching. If you are operating your own DNS server using BIND, the following commands help manage the service:
For managing BIND9 without restarting the service, use the rndc tool:

macOS

Commands to clear the DNS cache on macOS vary depending on the version:

Application-Level Troubleshooting

Modern web browsers provide specific URLs or internal settings to clear DNS and host caches. For instance, in Opera you can navigate to:
The image shows instructions for clearing the host cache in the Opera browser, with a search bar containing the URL "opera://net-internals/#dns" and a highlighted option to "Clear host cache."
For locally running or desktop applications, simply restarting the application might be sufficient to clear its DNS cache.

Debugging Incorrect DNS Responses

If you suspect that DNS responses are incorrect or inconsistent due to caching issues or unsynchronized authoritative nameservers, query the nameservers directly to compare their responses. Use the following commands with dig or nslookup:
If the responses differ, it might indicate a zone transfer or synchronization issue. To further diagnose such discrepancies, check the SOA serial numbers from the authoritative nameservers:
A mismatch in SOA serial numbers confirms a synchronization issue between the nameservers. By following these structured troubleshooting steps—from network connectivity assessments to operating system and application-level checks—you can systematically identify and resolve many common DNS issues. This approach not only helps in isolating the problem but also ensures that corrective actions are efficiently implemented.

Watch Video