PuppyIP Resource Center
Network & Connection Troubleshooting 7 min read Published 2026-11-17

Intermittent NXDOMAIN that later resolves: check authoritative DNS and negative caching

When a name returns NXDOMAIN and later resolves, compare the same record at authoritative DNS, recursive resolvers and the local client, and record SOA data and TTLs.

NXDOMAIN DNS troubleshooting negative caching authoritative DNS

Service eligibility and regional restrictions

PuppyIP serves only compliant overseas businesses and their authorized personnel. Proxy services are not available in mainland China. The service may only be used for lawful business activities outside mainland China. Use of this service within mainland China is prohibited.

Hosting a proxy IP or server overseas does not change these restrictions. The service must not be provided to end users in mainland China through relaying, forwarding, sharing or resale. Before use, read the Terms of Service.

Key Takeaways

  • NXDOMAIN means a resolver judged the name nonexistent; an existing name with no A record can produce a different response.
  • A later successful lookup does not by itself prove that a cache expired. Compare authoritative data, recursive resolvers and the client path.
  • Repeat the same query type on the same network and resolver, keeping the response's SOA data and TTL.
  • Correct a record only after confirming that the authoritative entry is missing or wrong; do not flush every device or router cache by default.

Distinguish NXDOMAIN from a missing record type

NXDOMAIN means the queried name does not exist in the DNS view consulted by that resolver. If the name exists but has no A, AAAA or other requested record, the response may instead be NOERROR with an empty answer section. CNAME chains, delegated zones and split-view DNS can also affect the result, so a browser's “name does not exist” message is not enough to identify the failing layer.

If a name first returns NXDOMAIN and later works, possible explanations include cache lifetime, propagation of authoritative data, different recursive resolvers or a different client network path. Without recording each response, the time until recovery cannot identify the cause on its own.

Record the full response from the same client

Keep the domain and record type constant, then query from the same device and network where the problem appears. Record the time, response status, answer section and authority section. Do not keep only the returned address: SOA data and TTLs in a negative response help assess negative caching. These commands send DNS queries and do not change local settings.

Record the name, query type, time and DNS response

sh
DOMAIN='REPLACE_WITH_AUTHORIZED_DOMAIN'
TYPE='A'
date -u
dig "$DOMAIN" "$TYPE" +noall +answer +authority
Run on Linux or macOS with dig installed. Replace the domain and record type with values you are authorized to check. This queries DNS without changing system settings.

Compare recursive answers with the authoritative path

Repeat the same query through the recursive resolver actually configured on the system and compare it with another resolver you are authorized to use. If resolvers return different states, first check whether they are querying the same zone, delegation and DNS view. A public recursive resolver is not a substitute for authoritative data controlled by the domain owner.

dig +trace follows the delegation path one step at a time and may be affected by network policy, firewalls or DNSSEC. If the trace differs from a direct authoritative response, record the servers and answers before deciding what to change. Do not replace the system resolver because a single query failed.

Compare a recursive answer with the delegation path

sh
DOMAIN='REPLACE_WITH_AUTHORIZED_DOMAIN'
TYPE='A'
RESOLVER='REPLACE_WITH_APPROVED_RECURSIVE_RESOLVER'
dig @"$RESOLVER" "$DOMAIN" "$TYPE" +noall +answer +authority
dig +trace "$DOMAIN" "$TYPE"
Replace the resolver placeholder with an approved recursive resolver. Trace sends multiple DNS queries; follow local network policy on restricted networks.

Check whether the application uses the system resolver

The operating system, browser secure DNS, VPN, proxy client and router forwarder may use different resolvers. On Linux, getent follows the system NSS path; resolvectl is available on systems using systemd-resolved. If their results differ, check whether the application uses the system resolver and whether a VPN, proxy or browser has its own DNS setting.

Do not clear browser, system and router caches at the same time. A flush changes test conditions and can hide an authoritative-record or delegation problem that remains. Compare responses first, then follow documentation for the specific layer whose cache is confirmed to be involved.

Inspect the system name-resolution result

sh
DOMAIN='REPLACE_WITH_AUTHORIZED_DOMAIN'
getent ahosts "$DOMAIN"
resolvectl query "$DOMAIN"
Linux commands; resolvectl applies only to systemd-resolved. They query the local resolution path. Output may contain private names, so redact it before sharing.

Change a record only when authoritative data is wrong

If authoritative servers consistently return NXDOMAIN and the expected name is absent from the correct zone, confirm the record name, type, zone owner and change authorization. Then add or correct only that record in the DNS provider's authoritative record interface. Record the previous value and TTL, and change entries one at a time; do not rebuild an entire DNS zone to fix one name.

If the authoritative answer is correct while a recursive resolver still returns NXDOMAIN, compare the SOA negative-cache TTL and that resolver's state. Negative caching may preserve an earlier result until its TTL expires, but different resolvers, DNSSEC validation or delegation problems can also produce differences. There is no universal wait time; recheck each resolver against the observed TTL and response.

Verify through the same client path

After a change, repeat the original query from the client and network where it failed, using the same name and record type. Check both authoritative servers and the recursive resolver in actual use. Confirm that the expected A/AAAA record or CNAME chain appears, the status is expected and the application uses the intended resolution path.

If no authoritative record changed and the name later began resolving, that only shows the response changed; it does not identify a particular DNS cache as the cause. Keep the earlier and later responses with their SOA data and TTLs before deciding whether more investigation is needed. A SERVFAIL response calls for a separate check of delegation, DNSSEC or upstream errors; it is not the same condition as NXDOMAIN.

Sources

Frequently Asked Questions

Is NXDOMAIN the same as having no A record?

No. NXDOMAIN means the name does not exist. An existing name without an A record commonly returns NOERROR with an empty answer; check other record types and any CNAME chain as well.

Does a later successful lookup prove negative caching expired?

No. Different resolvers, authoritative-data propagation, DNS views or client paths can produce different results. Compare the actual responses and SOA TTL.

Should I flush the router's DNS cache first?

No. Compare the same query at the authoritative servers, recursive resolver and client first. A flush changes test conditions and cannot correct a bad authoritative record or delegation.