Pcornel
Browse topics
Options
Recent
Favorites
Networking · Technical reference

DNS (Domain Name System)

Direct answer

DNS resolves names through recursive resolvers, authoritative servers, caches and typed resource records.

When to use this

Use it to separate client resolver configuration, transport, delegation, authoritative data and caching failures.

First 30 seconds

1. DNS translates names to addresses.

2. Resolvers recurse; authoritative servers answer for zones.

3. TTL controls caching.

4. Check forward and reverse records.

5. Device resolvers needed for name-based config.

Operational verification

client → resolver → recursion → authoritative → answer cached

Evidence · next step

1. Record queried name/type and resolver.
2. Test reachability and UDP/TCP 53.
3. Query the recursive resolver.
4. Trace delegation/authority when needed.
5. Compare TTL/cache, DNSSEC status and application behavior.

Continue only after interpreting the current observation.
Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
Protocol standard + deployed implementation
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformProtocol standard · Cisco IOS / IOS XE · Linux
Key commandip name-server <dns-server>
Scope / prerequisiteUse it to separate client resolver configuration, transport, delegation, authoritative data and caching failures.
Show · 1Verify · 1Reference · 9
What next?3 suggested next steps
Child topics (this level)7
Catalog command links11
Evidence1
On this pageJump to a specific section
Cisco IOS / IOS XE first

Primary Commands

Configuration and operational commands for this Topic.

Verification

Show Commands

Read-only Cisco show commands for confirming state, narrowing a fault and interpreting the current boundary.

Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

4 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Checking DNS from a client Verify boundary
dig www.example.com
dig www.example.com @10.0.0.53
dig www.example.com @ns1.example.com +norecurse
dig -x 192.0.2.10
nslookup www.example.com
ping www.example.com

dig shows the status of the lookup, the answer with its remaining time to live, and which server answered. Naming a server with @ tests that server; asking a domain's own server with +norecurse shows the current content of the zone, without any cache. -x performs a reverse lookup. nslookup is the equivalent on Windows. A ping by name on a Cisco device or a host shows whether the system itself can resolve.

On a client, check which resolver it actually uses: ipconfig /all or resolvectl status.

Known-good: the name resolves to the expected address through the resolver the client uses, and the domain's own servers give the same answer.

Step 2 Verification and output interpretation Verify boundary

Query the exact record type and compare recursive and authoritative answers when source-of-truth matters. Inspect answer data, TTL, response code and authority context rather than only whether a command printed an IP address. If a resolver returns stale or unexpected data, compare it with a direct authoritative query and account for cached TTL/negative responses. Verify A and AAAA independently where both exist. After name resolution is confirmed, test the actual transport/application separately using the returned address; DNS success and application success are distinct boundaries.

Step 3 Verification & troubleshooting Narrow the fault

1. Record queried name/type and resolver.

2. Test reachability and UDP/TCP 53.

3. Query the recursive resolver.

4. Trace delegation/authority when needed.

5. Compare TTL/cache, DNSSEC status and application behavior.

Step 4 Branching troubleshooting Narrow the fault

Path: Networking → IP Services → DNS. Local intent: DNS: Resolver, Recursive lookup, Authoritative server, A record.

Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

command output · 1
Command lookup Jump straight to Cisco syntax
Drill down

Subtopics

Go one level deeper into this subject.

Troubleshooting trees

Start from the symptom

Prove the nearest boundary, branch on the observation, and repeat the original test after the minimum controlled change.

Symptom-first flow Name lookup fails while direct IP connectivity works 7 decision steps

First proof

Keep DNS separate from generic IP reachability: prove resolver selection, transport and answer semantics.

Useful read-only checks: show hosts · show ip route

Step 1 Direct IP baseline Observe → decide

Confirm the original destination is reachable by IP.

If healthy: IP path works independently of DNS.

If broken: If IP also fails, return to routing/path troubleshooting.

Step 2 Resolver identity Observe → decide

Confirm which DNS server the client is actually using.

If healthy: Client targets the intended resolver.

If broken: Correct DHCP/static resolver configuration.

Step 3 Resolver reachability Observe → decide

Prove IP and transport reachability to the resolver.

If healthy: Queries can reach the resolver and replies can return.

If broken: Investigate route/ACL/firewall before DNS record content.

Step 4 Query/response semantics Observe → decide

Inspect whether the response is NOERROR, NXDOMAIN, SERVFAIL or timeout.

If healthy: Response code matches the expected answer state.

If broken: Use the exact response class to choose authoritative/recursive next checks.

Step 5 Record path Observe → decide

Check A/AAAA/CNAME/PTR chain relevant to the original name.

If healthy: The intended record chain resolves.

If broken: Correct record/zone/delegation rather than network path.

Step 6 Cache/TTL boundary Observe → decide

Compare cached answer with authoritative/current expectation.

If healthy: Cache state and TTL are plausible.

If broken: Expire/flush only when cache evidence warrants it.

Step 7 Repeat the original name-based test Observe → decide

Use the same hostname/application request.

If healthy: Name-based application flow succeeds.

If broken: A successful lookup does not prove the application itself.

Proof limit

A passing step proves only that boundary; continue until the original symptom is explained and retested.

Failure signatures

Recognize the symptom, then prove the boundary

Observed symptom → candidate boundary → discriminating check → original-test closure. A signature narrows the search; it never proves root cause by itself.

DNS returns SERVFAIL
1 · Observe

A resolver answers but reports that it could not complete processing for the query.

2 · Candidate boundaries

resolver recursion/upstream · DNSSEC/validation · authoritative reachability · timeout/dependency

3 · Discriminate

query the same resolver explicitly → compare authoritative/upstream path → check whether failure is name-specific

4 · Proof limit

SERVFAIL is not NXDOMAIN and does not prove the requested name does not exist.

Repeat the original failing test after the minimum controlled change before calling recovery verified.
DNS returns NXDOMAIN
1 · Observe

The responding DNS authority/resolution chain reports the queried name does not exist.

2 · Candidate boundaries

wrong query/suffix · authoritative data · split-DNS/view boundary · stale negative cache

3 · Discriminate

verify exact FQDN → query authoritative context where appropriate → compare another resolver/view

4 · Proof limit

NXDOMAIN does not prove general DNS transport/connectivity is broken.

Repeat the original failing test after the minimum controlled change before calling recovery verified.
Operational depth

DNS operational boundary

Boundary-first guidance: prove the nearest state before moving outward.

Fast answer

Separate name resolution from IP reachability and application behavior. A successful DNS answer proves resolution only.

Boundary chain

client resolver → configured resolver → recursive/authoritative answer → returned address → route/transport → application

Healthy

Expected name returns the intended record and direct-IP/application tests agree with the resolved destination.

Broken

NXDOMAIN, SERVFAIL, timeout or an unexpected record is isolated before routing/application conclusions are made.

Does not prove

A DNS answer does not prove the destination is reachable, TCP/UDP is permitted, TLS succeeds or the application is healthy.

Key points
  • A/AAAA map names to IPv4/IPv6; CNAME aliases one name; PTR is reverse lookup
  • Recursive and authoritative roles answer different questions
  • UDP 53 is common, while TCP 53 is required for some large replies and zone operations
  • NXDOMAIN, NODATA, SERVFAIL and timeout indicate different boundaries; TTL controls cache lifetime.
Key checks
  • nslookup <name> — resolution
  • dig <name> +trace — delegation path
  • show hosts — cached names on IOS
  • show running-config | include name-server — device resolvers
ReferenceHow it works1 section · depth on demand

How DNS works

Who does what. A device sends its question to the resolver it has been configured with. The resolver finds the answer on the device's behalf — from its cache, or by asking the servers responsible for the name, starting from the root and following referrals — and returns it. The servers that hold a domain's actual records are its authoritative servers.

Records. DNS data consists of records, each with a type:

TypeHolds
A / AAAAAn IPv4 / IPv6 address for a name
CNAMEAn alias pointing to another name
MXThe mail servers for a domain
NSThe servers responsible for a domain
PTRThe name for an address (reverse lookup)
TXTFree text, used for mail policies and verification

Caching. Every record carries a time to live. Resolvers and clients keep answers for that long and do not ask again in between. A change therefore reaches users gradually, as cached copies expire — and a "name does not exist" answer is cached too.

Transport. Queries normally use UDP port 53. Answers too large for UDP are fetched again over TCP port 53, so both must be permitted.

Possible results of a lookup. An answer; "the name does not exist" (NXDOMAIN); the name exists but has no record of the requested type; a server failure (SERVFAIL); or no response at all.

On a Cisco device, DNS is needed only for the device's own lookups:

ip name-server 10.0.0.53
ip domain name example.com
ip domain lookup

A useful habit: when an application cannot connect, first separate the two steps — does the name resolve, and does the resulting address answer.

ReferenceImportant terms & boundaries3 sections · depth on demand

In depth

DNS concepts that explain real problems

RFC 1034 defines the DNS model behind every lookup. Names are made of labels of up to 63 octets, and a full name can be up to 255 octets. Comparisons ignore case, but the original case is kept. The name space is split into zones, and a parent delegates a subtree with NS records at the zone cut. Glue address records are needed when a name server's own name lies inside the delegated zone.

Roles (RFC 1034)

ComponentFunction
Authoritative name serverHolds zone data and answers from it
Recursive serverResolves on behalf of clients, using its cache
Stub resolverThe client library that relies on a recursive server
CacheKeeps answers for their TTL

Query types and header bits

ModeBehaviour
Iterative (non-recursive)The server answers or refers; all servers must support it
RecursiveRequested with RD; offered with RA; optional for servers

Caching rules (RFC 1034)

RuleEffect
The zone administrator sets the TTLChanges take up to the old TTL to reach every cache
A TTL of 0 prohibits cachingEvery query goes to the authoritative server
Authoritative data wins over cached dataA server never prefers its cache for its own zone
Negative caching uses the SOALookups for missing names are cached as well
No other data at a CNAME nodeMixing a CNAME with other records breaks lookups
host$ dig +norecurse @ns1.example.net www.example.net A
;; flags: qr aa; QUERY: 1, ANSWER: 1
host$ dig +trace www.example.net
host$ dig www.example.net A | grep -E "^www|Query time"
www.example.net.  287  IN  A  192.0.2.40
R1(config)# ip name-server 10.20.0.53 10.20.0.54
R1(config)# ip domain lookup source-interface Loopback0
R1# show hosts summary

Troubleshooting by symptom

SymptomWhere to look
Works for some users onlyDifferent resolvers or cached answers; compare TTLs
A change isn't visibleThe old TTL hasn't expired yet; negative caching
SERVFAILBroken delegation or missing glue; DNSSEC failures
NXDOMAIN for a name that existsWrong zone, typo, split-horizon view

Before a planned change, lower the TTL by at least the current TTL. That way old answers have expired by the time the change is made.

Documented example, not captured output.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.

Concept and state model

A DNS query asks for a specific name, class and record type. A recursive resolver may answer from cache or follow delegations toward authoritative servers, while an authoritative server answers from the zone data it serves. Common records include A/AAAA for addresses, CNAME for aliases, MX for mail routing, PTR for reverse mapping and NS/SOA for zone authority. TTL controls how long positive data can remain cached; negative responses can also be cached according to DNS rules. CNAME changes the canonical name being resolved and may require additional lookups before an address is returned. DNS transport commonly uses UDP for ordinary queries and TCP where message size, transfer or fallback behavior requires it.

Operational boundaries and common misconceptions

A successful A or AAAA answer does not show the host responds, the service listens, routing works or TLS identity is valid. NXDOMAIN means the queried name does not exist according to the answering authority/cache; NOERROR with an empty answer has different semantics. A CNAME answer is not the final address result. Different clients can legitimately see different answers because of split DNS, cache state, geography or policy. Always preserve which resolver was queried and whether the result came from cache or authority when comparing observations.

ReferenceConfiguration & state1 section · depth on demand

Configuration model and design choices

Keep zone ownership and delegation explicit. Authoritative records should have intentional TTLs, and aliases should not create loops or hide conflicting ownership. When an application depends on both A and AAAA records, publish only addresses with valid service paths or understand how client address-selection/fallback behaves. Resolver configuration on clients should point to recursive resolvers appropriate for the environment rather than directly to arbitrary authoritative servers. Split-horizon/internal DNS designs should document which clients receive which answer set so identical names do not create accidental ambiguity.

Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docProtocol standard + deployed implementation RFC 1034

Authoritative/upstream documentation reviewed for bounded claims in IP Services → DNS. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://www.rfc-editor.org/rfc/rfc1034.html · confidence 94%
Terminology layer

Terms & aliases

Hover a linked term for a quick definition; click it to open its glossary entry. Aliases are other names that find this Topic in search.

Aliases that resolve here
domain name systemDNS resolver authoritativeA AAAA CNAME PTR
Embedded reference data

Quick lookup tables

DNS evidence chain

Configuration, operational state, counters and downstream proof remain separate.

BoundaryQuestionEvidenceDoes not prove
DefinitionWhat is configured or intended?running configuration / controller policylive operation
Local stateIs the feature active at the expected scope?show hostsremote success
CountersDid controlled traffic or an event reach this stage?scoped counters/timestampscomplete return path
Next boundaryWhat consumes or transports this state?client stub → recursive resolver/cache → root/delegation → authoritative answer → cached response → applicationapplication success

DNS · reference boundaries

Compact technical reference for the most important state and interpretation boundaries.

DNS conceptReference meaning
Recursive resolverFinds/caches answers for clients
Authoritative serverPublishes source data for a zone
TTLCache lifetime for an RRset
CNAMEAlias to another canonical name
NXDOMAINName does not exist (not the same as empty answer)
Confirmation

Confirm action

Continue?