DNS Not Resolving: Fix It in 5 Minutes
Stop DNS not resolving with this evergreen 5-step checklist. Audit, harden, and verify your resolver configuration safely.

On this page
TL;DR — Key takeaways
- Start with a single failing host, then isolate whether the issue is local, network-wide, or provider-side.
- Run dig and nslookup from the affected host, check /etc/resolv.conf, and verify the resolver responds.
- Harden DNS by disabling recursion on public resolvers, enabling DNSSEC validation, and filtering malicious zones.
- Backup configuration files before changing resolvers, and roll back if a change breaks name resolution.
- Verify the fix with a second resolver, a different network path, and a DNS security scanner before declaring the issue closed.
DNS not resolving is one of the most common and frustrating support tickets. The site is up, the server is online, but browsers show a connection error. The cause is usually a misconfigured resolver, a firewall rule, or a provider change. This guide covers a step-by-step fix, a security audit checklist, and hardening steps you can apply without breaking name resolution.
Why DNS Stops Resolving
DNS resolution fails when a client cannot reach a working resolver, or when the resolver itself returns an error. Common causes include a misconfigured /etc/resolv.conf, a firewall blocking UDP port 53, a corporate proxy intercepting DNS, or a provider outage. The first step is always to isolate the failure. Test one host, then check the network path, then verify the resolver itself.
- Local issue: the client cannot reach the configured resolver.
- Network issue: UDP 53 is blocked or intercepted by a proxy.
- Resolver issue: the upstream server returns SERVFAIL, NXDOMAIN, or times out.
- Configuration issue: resolv.conf points to a stale or wrong IP.
Step-by-Step Fix for DNS Not Resolving
Start with the affected host. Run dig +trace example.com and nslookup example.com. If the query times out, the client cannot reach the resolver. If the trace stops at a specific server, the network path is broken. Check /etc/resolv.conf and verify the nameserver IP. If the file points to a stale IP, update it to a current resolver. Backup the file before changing it, then test with dig again.
- Run dig +trace and nslookup from the affected host.
- Inspect /etc/resolv.conf and note the configured nameserver.
- Backup the file, then update the nameserver if the IP is stale.
- Test with dig +short example.com to confirm resolution works.
- If the issue persists, check firewall rules and proxy settings.
Security Audit Checklist for DNS
A secure resolver does not expose recursive queries to the public internet, does not accept queries from untrusted networks, and validates DNSSEC. Run a quick audit. Check whether your public resolver accepts recursive queries from any IP. If it does, restrict access to trusted networks. Enable DNSSEC validation on clients that support it. Monitor query logs for NXDOMAIN floods and suspicious domain patterns.
- Verify recursive queries are not open to the public internet.
- Enable DNSSEC validation on resolvers that support it.
- Check for open port 53 on public interfaces.
- Review logs for repeated SERVFAIL or NXDOMAIN responses.
- Block DNS over untrusted networks with firewall rules.
How to Harden Your DNS Configuration
Harden DNS by choosing a trusted resolver, disabling recursion on public-facing servers, and validating DNSSEC. If you run your own resolver, restrict recursive queries to internal networks and use access control lists. If you use a managed DNS provider, enable DNSSEC and set up a secondary resolver. Test the change on a single host first, then roll it out to the rest of the fleet.
- Use a trusted, validated resolver for internal clients.
- Disable recursion on public-facing DNS servers.
- Enable DNSSEC validation on all clients that support it.
- Test on one host, then roll out to the rest of the fleet.
- Keep a rollback plan for resolver configuration changes.
How to Verify the Configuration Is Secure
Verification is not a single command. Run dig +short example.com to confirm resolution works. Run dig +dnssec example.com to confirm DNSSEC data is present. Use a DNS security scanner to check for open recursion and missing DNSSEC validation. Test from a different network path to confirm the fix is not local. Monitor logs for 24 hours to confirm the resolver is stable and not returning errors.
- Run dig +short example.com to confirm resolution works.
- Run dig +dnssec example.com to confirm DNSSEC data is present.
- Use a DNS security scanner to check for open recursion.
- Test from a different network path to confirm the fix is stable.
- Monitor logs for 24 hours after the change.
Quick troubleshooting checklist
- Confirm the failure is isolated to one host or affects all clients on the network.
- Run dig +trace and nslookup from the affected host to identify where resolution stops.
- Inspect /etc/resolv.conf and the systemd-resolved or NetworkManager configuration.
- Check for firewall rules, proxy settings, and corporate DNS interception on the client.
- Validate DNSSEC status and disable open recursion on public resolvers.
- Backup /etc/resolv.conf and resolver configuration before making changes.
- Test the new resolver with dig, host, and a DNS security scanner.
- Monitor logs and query success rates for 24 hours after the change.
FAQ
Why does DNS not resolve on one device but work on others?
The issue is usually local to that device. Check its /etc/resolv.conf, proxy settings, firewall rules, and the DNS resolver it points to. If other devices resolve fine, the problem is not your network or provider.
How do I harden DNS without breaking name resolution?
Back up your current resolver configuration first. Then switch to a validated, trusted resolver, enable DNSSEC validation, and disable open recursion. Test with dig and a DNS security scanner before removing the old resolver from the list.
What is the fastest way to confirm DNS is working?
Run dig +short example.com from the affected host. If it returns an IP address, resolution is working. If it times out or returns SERVFAIL, check the resolver, firewall, and network path.
Related articles
- Hosting OperationsDNS Not Resolving: 5 Fixes & Security HardeningFix DNS not resolving errors by checking TTLs, cache, and zone files. Secure your resolver against cache poisoning and unauthorized zone transfers.
- Hosting OperationsDNS Not Resolving Not Working: Security Hardening GuideSecure your DNS infrastructure with threat modeling, hardening steps, and audit checklists. Practical guide for hosting teams and website owners.
- Hosting OperationsDNS Not Resolving Error — 7-Step Fix (2026)Fix DNS not resolving error with a 7-step checklist. Audit, harden, and verify your DNS configuration for 2026 security.
- Hosting OperationsHow to Fix Email Not Sending (2026)Fix email not sending with a security-hardening checklist. Audit your server, tighten authentication, and verify delivery step by step.
- Hosting OperationsDNS Not Resolving: Step-by-Step FixDNS not resolving? Compare common causes, test with real commands, and apply the right fix for your setup. Follow this evergreen troubleshooting guide.
- Hosting OperationsFix Website Down Not Working (2026)Website down not working? Follow this security-hardening checklist to audit logs, lock down access, and verify your server is safe and reachable.