Chapter 9: Domain Names, DNS and Subdomains
9.2 How DNS resolution works
Friends, when you type a name, how does the browser get the IP? The journey is below in six steps – once you understand it, you can solve most DNS problems yourself.
मित्रांनो, तुम्ही नाव टाइप केल्यावर ब्राउझरला IP कसा मिळतो? हा प्रवास खाली सहा स्टेप्समध्ये आहे – एकदा समजला की DNS चे बहुतेक प्रॉब्लेम्स तुम्ही स्वतः सोडवू शकाल.
दोस्तों, आप नाम टाइप करते हो तो ब्राउज़र को IP कैसे मिलता है? ये सफ़र नीचे छह स्टेप्स में है – एक बार समझ आ गया तो DNS के ज़्यादातर प्रॉब्लम्स आप ख़ुद सुलझा लोगे.
- The browser needs the host's address. Its name-resolution arrangement can use cached or local information or query a DNS resolver.
- A recursive resolver can answer from cache, use a configured forwarder or follow DNS delegations.
- In a cold iterative example, a root server refers the resolver to the applicable top-level servers.
- A top-level server can refer it to the delegated authorities for the next branch. Other relevant child delegations can add steps.
- The appropriate authoritative server supplies records, an alias or a negative answer. A positive A example for documentation could be
192.0.2.51, with a TTL. - The client uses the DNS result to select an address. It establishes a connection and, for ordinary HTTPS, verifies TLS before sending the named HTTP request.
Traditional unencrypted DNS can use UDP or TCP on port 53. A truncated UDP result can lead to a TCP retry. Other DNS transports also exist. These DNS exchanges happen separately from the later website request.
Ravindra Bagale's Tip
After a DNS change, compare the intended name and type at its authority and through the client’s resolver. An earlier cache can still return the old result. Keep the status and TTL in the full output.
Ravindra Bagale's Tip – मराठी
DNS बदलल्यानंतर योग्य नाव आणि record type authoritative server वर आणि client च्या resolver वर तपासा. जुने उत्तर cache मधून येऊ शकते. पूर्ण output मधला status आणि TTL लिहून ठेवा.
Ravindra Bagale's Tip – हिंदी
DNS बदलने के बाद सही नाम और record type authoritative server और client के resolver पर जाँचें. पुराना उत्तर cache से आ सकता है. पूरा output देखकर status और TTL दर्ज करें.
Lab
Chala, compare the two cache timelines in the exercise below. If your network permits the bounded public example, record the answer, status, TTL and query destination. An ordinary recursive lookup and an iterative trace show different observations.
Follow one DNS question to an answer
Friends, in the previous lesson the dairy printed a name on its receipt so customers would not have to memorize a number. Now suppose a customer asks for the pickup site from a laptop that has never visited it. How can the laptop find the network location without having a permanent list of every website? DNS assigns responsibility to parts of a shared directory. A program called a resolver can use that arrangement to obtain an answer or determine why an answer is unavailable. We will follow one question for the fictional pickup name, then see why the next customer may get the result from a cache.
Write the question precisely. We might ask for an A record for pickup.dairy.example.test. to find IPv4 data. A different question could ask for AAAA data for the same name. We are asking about the host, with a record type. We are not sending the rest of the URL, starting the web service, or asking whether the shop accepts a pickup request today. A successful DNS answer helps the client choose an address. The connection, any TLS checks and the HTTP request come later in the ordinary web visit.
The classroom tree below uses names under the reserved test suffix. The root and test-zone referrals in our worksheet are imaginary roles. The public DNS root does not delegate a real dairy site under that reserved suffix for this exercise. This lets us practice the logic without creating records. Later we will read a small amount of public information for a reserved documentation domain. Keep the supplied model and the live observation separate in your notes.
Find who asks on the client's behalf
Your browser needs a location for the hostname. It or the operating system may already have relevant information. Applications and systems vary in how they use their own caches, operating system name services, a local hosts mapping, a network resolver or an encrypted DNS service. There is no single required order in which every browser checks those sources. A command-line DNS tool typically sends a DNS query to its selected resolver and can bypass some of these local name sources. When two tools disagree, record how each actually obtains its answer.
On many systems an application hands the question to a small local component commonly called a stub resolver. It normally asks another resolver to do the full work on its behalf. That recursive resolver might be provided by a local network, an enterprise setup or a configured DNS provider. In an AWS VPC, Route 53 VPC Resolver can provide recursive resolution for clients that use it. That resolver role is distinct from a Route 53 public hosted zone's authoritative nameservers, which publish records for hosted domains. A vendor can offer both without the servers serving the same purpose.
A recursive resolver undertakes to return the requested answer where it can find it, or report an appropriate negative result or failure. It does not normally ask your browser to visit each DNS server in the hierarchy. The resolver can reuse suitable data from its own cache, consult its configured forwarder, or follow the hierarchy. An authorized operator troubleshooting an internal hostname needs to know which resolver should be asked. Attempting the same private name at a public resolver may report that it is unknown and can disclose an internal name. Keep private lookups in the environment intended for them.
A DNS query is identified by a name and type, plus a class such as Internet class, usually shown as IN. In the first exercise we use only IN. An A result tells you that a particular IPv4 address value was associated with the queried name. It does not tell you whether IPv6 is configured or which unit is listening on port 443. An answer can also point to an alias, in which case another name may need to be resolved. A mail result or name server result supplies data with a different meaning. The ticket should name what was actually asked and what came back.
Use the root, top-level and authoritative roles
Imagine a recursive resolver that lacks useful cached information and will follow DNS delegations itself. It knows how to reach the root DNS service. The root is authoritative for the root zone. It usually does not keep the final address of a site deep in a delegated branch. Instead it can give a referral to name servers for the next relevant part, such as the public top-level domain com. A referral identifies who to ask next. It is not the final address answer for the dairy. In a lesson diagram, put that referral arrow back to the resolver, because the resolver asks the next server.
The applicable top-level name server can refer the resolver to the delegated name servers for a more specific domain. Those delegation records reflect the arrangements supplied through the registry and registrar where applicable. If a separate child zone has been delegated, following the hierarchy can require another referral. Delegation marks a boundary where another authority manages records for a branch. The tree can have different depths in different places, so the exact number of query exchanges is not fixed at three. A name server for a zone may also provide address information needed to reach some delegated servers. This supporting information is often called glue when provided for that purpose in the referral.
When the resolver reaches a server with authority for the queried name, that server can respond with the relevant records, an alias, or an authoritative indication that the name or type is absent. The authoritative server's job is to publish data for its zone. It does not serve the website content. It also need not provide arbitrary recursive service to the client. Some programs or organizations operate recursive and authoritative functions together for particular deployments. Always describe the role a server performs in the given query.
Write an imaginary referral sequence using the workshop tree. The root role provides the next label's authorities. The test-zone role refers to authorities for the workshop's managed example branch. The workshop authoritative role returns the A data for the invented pickup host. We omit other delegation boundaries to keep the arrows readable. In a public lookup, a resolver with cached information may already know a more specific next server and need no fresh root query. A resolver may also minimize the name in questions sent higher in the tree instead of sending the entire original name at every step.
An alias can send the lookup down a different branch. Suppose the dairy's pickup name is configured to refer to a managed service name. The responding server can tell the resolver that canonical target. The resolver then obtains the necessary data for that other name, using caches or authoritative servers for a different zone as needed. Fixing one address at the dairy's zone is not the same as fixing an unreachable target controlled by a provider. Write down chain links before concluding which operator controls the final address. The records lesson will distinguish configurable DNS aliases from browser redirects.
Explain why two customers can see different addresses
DNS answers can be cached. Cache means a saved observation that can be reused for later requests. A record's time to live, TTL, is expressed in seconds and guides ordinary caching. When a recursive resolver answers from a positive cache, it can report how much of the cached lifetime remains. Two questions arriving seconds apart may see the same address with a smaller remaining TTL. The next refresh can make the value larger again. Different resolvers can have learned the record at different moments or use different valid policies. The number printed in one answer is not a worldwide countdown for every visitor.
Imagine the workshop resolver got an old address with a TTL of 120 at 10:00:00. It can ordinarily reuse it until the 120 seconds of that stored lifetime are gone. At 10:00:30 the authority changes to a new address. A second resolver that had no cached result can learn the new address immediately. At 10:01:00 the first resolver can still return its old value, with about 60 seconds of lifetime in our simplified model. A new lookup after that entry expires can fetch the new result. Both resolver outputs are understandable if you know what each learned and when.
Lowering the TTL for a future planned change can help if done before earlier long cached lifetimes have run out. It does not reach into a cache and retroactively modify a copy that already stored a longer lifetime. Likewise, raising a TTL only affects a version fetched with that setting. Choose change windows that account for the records involved, including delegation and alias chain data where relevant. This is more reproducible than telling the customer every DNS change must take an identical number of hours. Some resolvers can also serve stale cached data under particular failure conditions while refresh cannot obtain a useful response. Treat that as an additional behavior to consider when observed.
A client may save other pieces of state as well. The browser can reuse network connections. An HTTP cache can reuse a web response body while the resolver already has the new address. A lookup tool that reads the current answer cannot demonstrate which connection a particular tab reused. If a support report says the new DNS address is visible but an old page appears, compare the actual client's observed address, hostname, and HTTP behavior. Do not keep editing the domain values just because the page's cached content has a stale marker.
In a production change, first confirm the intended association at the relevant authoritative server or provider, then compare the client's recursive answer. Check the same name and type. A new A value says nothing about an unchanged AAAA value. If one client tries IPv6 and another uses IPv4, inconsistent readiness can look like random browser trouble. The practical next check is the separate DNS data and the actual address family used by a safe request, not a universal statement that one network is slow.
Separate absence from failure
A DNS answer can indicate an existing name with an available record. It can also indicate the name exists but no record of the requested type is available, often called NODATA. That state is not a distinct DNS response code. A response can say NOERROR with no applicable answer records, and the response context tells you whether it is an authoritative negative answer or something else such as a referral. NXDOMAIN indicates the queried name does not exist, subject to interpreting any aliases and the response context. An address-free result from a short command cannot reliably distinguish these observations by itself.
For an example, suppose pickup.dairy.example.test has only an A result. The name is present in the worksheet. A question for AAAA can report no data of that type. A question for new.dairy.example.test before it is published might instead report that the name is absent. When the DNS role publishes that new name later, a recursive resolver may still retain the earlier negative observation for a while. This is negative caching. It reduces repeated lookups for absent data and is also why “it never existed a minute ago” can remain visible after the records are added.
A resolver can often determine negative caching time from the authoritative zone's SOA information, following the applicable rules. SOA means Start of Authority and includes metadata for the zone. For ordinary authoritative negative responses, the negative lifetime is derived using the lower of the SOA record's TTL and its MINIMUM field. A resolver may apply its supported policies. The lesson's local replay uses an explicit small negative TTL so the timeline is easy to check. Public values will differ and a dashboard's TTL for the newly created positive record tells you only part of the story.
Temporary resolution failures are another category. SERVFAIL means a server could not complete the resolution successfully, which can involve upstream issues, misconfigured delegation or a DNSSEC validation problem. A network timeout means the diagnostic client did not receive the expected reply in the observed interval. Neither result proves that the owner name is unregistered or absent. Modern DNS requirements specify caching certain failures to avoid large waves of repeated queries. If a whole zone fails, repeat the right bounded observations and check the actual authority and validation path. Creating another A record does not address every failure to get an answer.
Read the DNS exchange separately from the website connection
Ordinary unencrypted DNS exchanges commonly use UDP or TCP on port 53. UDP can carry a question and response without first establishing a TCP connection. A response that will not fit a permitted size may indicate truncation, leading the client to retry using TCP. Implementations must also support ordinary DNS over TCP, and some exchanges use it for reasons other than large results. Zone transfers are a separate operation and should not be used as a normal client lookup. There are encrypted forms, such as DNS over HTTPS and DNS over TLS, that can use other transports or endpoints. Ask which exchange the diagnostic is observing.
The flags printed by a DNS tool can clarify which roles are involved. RD indicates that the client requested recursion in that message. RA indicates that the responding server offers recursion under its applicable configuration. AA means the answer is authoritative under DNS message rules. A DNS resolver can return a cached answer without the authoritative flag even when the information originally came from the correct authority. Confirm the specific server queried and the section that contains the result. Neither the DNS flags nor an address value proves a named website's certificate, port or content is correct.
A full result usually includes a header, question and one or more sections. In the question check the exact name, class and type. Read the header's status. The answer section may show a returned address or alias. The authority section can indicate a referral or include useful zone information for a negative response. An additional section can contain supporting records. A displayed SERVER line tells you whom the tool contacted for the response. It does not generally list every server a recursive resolver consulted to obtain the data. The tool's response time includes the query to that selected server and its work for that exchange.
In a simple network a standard DNS diagnostic might contact the configured local resolver. A browser with a different resolver setup may see something else. DNS over HTTPS uses HTTPS to carry a DNS exchange to a particular service. The subsequent website URL can then use a different HTTPS connection to the web endpoint. Encrypted DNS and a website's TLS certificate concern different connections. If you need to compare public and private answers, perform tests against the interfaces approved for each environment and state which resolver supplied each observation. The test tool is an observation point rather than a promise that it behaves exactly like every user application.
Replay two caches with a clock you can control
Run the following local Python 3 exercise. It uses two tiny resolver stores and an authoritative table. The time values are counters, so a full demonstration takes no real waiting. No name servers or network connections are involved. The values are for a teaching zone under the reserved test suffix and use addresses reserved for documentation. Before running it, predict when the first resolver changes its address and when the second resolver can learn the newly published name. The exercise models expiry and refresh, not the entire DNS protocol.
python3 - <<'PY'
pickup = "pickup.dairy.example.test."
new = "new.dairy.example.test."
zone = {pickup: {"A": "192.0.2.51"}}
ordinary_ttl = 120
negative_ttl = 45
def authoritative(name, kind):
if name not in zone:
return "NXDOMAIN", "-", negative_ttl
if kind not in zone[name]:
return "NODATA", "-", negative_ttl
return "ANSWER", zone[name][kind], ordinary_ttl
def ask(label, cache, now, name, kind):
# This cache tracks exact questions, not all DNS negative-cache rules.
key = name, kind
if key in cache and now < cache[key][2]:
status, value, end = cache[key]
source = "cache"
else:
status, value, ttl = authoritative(name, kind)
end = now + ttl
cache[key] = status, value, end
source = "authority"
print(f"{label} t={now:03} {name} {kind}: {status} {value}, remaining={end-now}, {source}")
return status, value
left, right = {}, {}
assert ask("left ", left, 0, pickup, "A") == ("ANSWER", "192.0.2.51")
assert ask("right", right, 20, new, "A")[0] == "NXDOMAIN"
zone[pickup]["A"] = "192.0.2.71"
zone[new] = {"A": "192.0.2.72"}
print("t=030 authority replaces pickup address and publishes the new name")
assert ask("right", right, 35, pickup, "A") == ("ANSWER", "192.0.2.71")
assert ask("right", right, 40, new, "A")[0] == "NXDOMAIN"
assert ask("left ", left, 60, pickup, "A") == ("ANSWER", "192.0.2.51")
assert ask("left ", left, 60, pickup, "AAAA")[0] == "NODATA"
assert ask("right", right, 65, new, "A") == ("ANSWER", "192.0.2.72")
assert ask("left ", left, 120, pickup, "A") == ("ANSWER", "192.0.2.71")
PY
Read the left cache first. At time zero it receives the old A value and can reuse it until time 120. At time 60, the authority has updated but the earlier entry still provides the old value with 60 seconds remaining. The left cache also asks the independent AAAA question. The name exists in the authoritative teaching table but has no AAAA entry, so the model reports no data for that type. At time 120, the simple rule treats the A result as expired and returns the new A value from the authority. The old record and the new one coexist only as observations from different stores and moments.
Read the right cache next. It asks for the new name at time 20, ten seconds before the authority publishes it. The stored negative observation has a lifetime of 45 seconds and therefore expires at time 65. It asks for the updated pickup address at time 35 and can see the new value because it had no matching positive cache entry. It still sees the cached negative result for the separate new host at time 40. At time 65 that result expires and it learns the new address. The same recursive resolver can simultaneously show fresh and cached outcomes for different names and types.
The script deliberately stores a negative result against the exact question it received. The real rules can apply an NXDOMAIN result more widely to that name, and can account for alias chains or more specific cases. The exercise also omits server failures, refresh attempts and stale-answer behavior, which are implementation and policy topics. Treat its exact times as consequences of the model. When reading an actual answer, use the header, queried name, type, authority evidence and observed TTL together. No services, files or names are left to clean up by running the provided model.
Choose a follow-up task. Move the authoritative address change later on your paper timeline but keep the first query at zero. Have your partner predict separately how the established cache and one fresh resolver would answer. Then try a variant of the negative story where the new hostname exists early but has only AAAA data. Which negative category now fits the A question? Show the lookup type and value on your worksheet. This task is complete when your answer follows from the initial exchange and the matching cache age instead of using an unexplained waiting period.
Read a bounded public example
If your learning machine has dig, compare the worksheet with a small read-only observation for IANA's example domain. The two A questions use the same spelling and record type. The third asks for the example zone's nameservers. The commands use the resolver selected by dig's normal network settings. They request a complete view with limited retry and wait duration. Use only this reserved public example and an approved network. The local model is sufficient if no DNS tool or permitted network is available.
dig +time=3 +tries=1 example.com. A
sleep 1
dig +time=3 +tries=1 example.com. A
dig +time=3 +tries=1 example.com. NS
Read the header, answer data and responding server for each request. A successful query for example.com may return more than one A value. Those values and their TTLs can vary over time. Compare matching returned records instead of expecting the exact printed addresses from another machine. The TTL may decrease if the same answer is served from a cache. It may remain similar or change for other reasons, such as a fresh answer, policy, resolver selection or a changed cached value. The output does not expose your provider's complete internal cache state.
For the last query, the answer values should be names of authoritative name servers where the configured resolver can resolve this public example. A nameserver answer is not the web site's address. Reading those names through a recursive server is also different from showing a complete chain of referrals. In a longer investigation, a tool such as dig +trace can perform its own iterative walk. That requires a network that allows direct queries to the relevant authorities. A normal nslookup command reports a recursive lookup in typical use, not an equivalent trace. Do not treat a blocked direct trace as proof that the configured resolver or the website fails.
For the notebook, write the query name, type, exact result status, answer values, TTLs if relevant and the responding resolver. Keep a separate line for what the test cannot conclude. A report that says only “dig succeeded” can hide a genuine negative result or a response from the wrong provider. Full output also helps when checking NODATA versus NXDOMAIN. Avoid sharing unrelated network configuration, internal resolver names or user identifiers from a production tool output. Our examples only ask about the reserved public documentation domain.
Choose a next test for three common tickets
Ticket one says the new site works for the office and fails at home. Write the exact host and type being checked by both clients. The office may use an internal resolver, while home uses another path with different cached information. One could select IPv6 while the other uses IPv4. Compare the intended authoritative data in the applicable environment, then compare the configured recursive observations and TTLs. Record whether each client actually received an address. If one browser instead reports a certificate issue after connecting, follow that endpoint and hostname while keeping a separate line for the DNS result.
Suppose the two resolvers agree on A but return different AAAA evidence. The home client may be trying an IPv6 address associated with an old endpoint. Confirm which family it selected and whether that specific endpoint can serve the name. A deliberate staged rollout can publish only the families the service has verified. Changing a live record requires the authorized owner and a plan for cached clients. The point of the exercise is to locate the difference, not to force every client onto an address family before checking readiness.
Ticket two says the operator saved a new value but the authoritative answer looks unchanged. Identify the delegated provider and the particular zone before assuming cache. Two hosting providers or two hosted zones in one account can have copies with the same domain spelling. Only the delegated authority answers the applicable public path. If a query to a confirmed authoritative server shows the older value after the intended apply, inspect the selected zone, record owner, type and deployment status. Compare the relevant providers and exact names. A stale local browser cache cannot rewrite a separate authoritative reply observed from the correct server.
For the same ticket, check whether the operator set a record owner at the right relative level. A control panel can append its zone suffix to the field it expects. Entering a whole name in an input that expects a label can create an unintended longer owner. The authoritative check for the intended exact name will reveal the discrepancy. Search the relevant managed zone view deliberately rather than copying a second conflicting record. This kind of mistake has a different remedy from waiting for a previous cache entry to expire.
Ticket three says a new name worked after a delay despite no further edit. Consider whether the resolver cached earlier absence before the name was published, or whether a provider or delegation change was still becoming observable. In the lab model, the earlier negative expires and the next lookup learns the now-present name. In real operations, ask which status was seen before publication and which server responded. A prior NXDOMAIN, a NODATA response and a timeout have different meanings. Document the authoritative state when available and the offset or time of each observation. With only the report that it took a while, the cause remains a hypothesis.
There is a useful sequence for your own investigation notes. Start with the supplied report, then name the earliest verified failing stage. Read the exact question asked and answer context. Change only the question or one observation point at a time so you can explain what the changed result proves. If the problem is later than DNS, send the hostname, observed address and intended web path to the hosting owner. If this is a DNS responsibility issue, include the delegation, quoted status and relevant answer. This handoff uses information a teammate can repeat without exposing all local system settings.
As a team task, choose one of the three tickets and play the two roles. The first student proposes a cause, and the second chooses a comparison that would disprove it. For example, directly observed authoritative data matching the old value makes “only the browser cache is old” an inadequate account. A new authoritative value and a prior cached value make cache timing plausible, but verify the observed TTL and route before claiming the exact expiry. During discussion, separate readings that came from different DNS names, types and resolvers just as you separated host and path in the first lesson.
A referral itself can be cached, so a resolver might consult a provider you expected to retire. An address edit within the same authority changes the answer while leaving the parent delegation in place. A change to which authority serves the zone changes the referral and can leave older resolvers legitimately using prior delegation information. Keep both kinds of evidence in your plan. When the project is an approved provider migration, prepare the full zone on the next provider and verify the correct copies while coordinating continuity of the old service. A TTL printed for one A result cannot tell you how long every resolver will remember which authoritative server to contact.
For another example, imagine a cached referral points to two authoritative names, and a resolver receives a different response from each. In that case, compare the queried names, types, flags and answer values from the actual servers where you have an approved diagnostic route. Both authorities should serve the intended state for the applicable version of the zone. Different values may be deliberate under a routing policy, or they can signal an incorrect or incomplete deployment. Confirm the documented expected behavior before declaring a discrepancy. A cache comparison is most useful when you also understand which answers the authority was intended to provide.
As a final prediction, choose a failing browser report after a change and mark the first observation you would need to separate these explanations. A name lookup failure needs the DNS status. A completed TLS handshake with a wrong HTTP body needs the requested host and response evidence. An authoritative answer agreeing with the new plan but a resolver still returning the old one needs the selected type, observed TTL and route through that resolver. The sequence helps you prioritize the first available evidence for a fellow learner. A correct explanation identifies one observation that would make you change your mind.
Answer with the resolver and the question
What is the difference between a recursive resolver and an authoritative server?
A recursive resolver answers client questions by reusing cached information, using configured forwarding or obtaining information from the hierarchy. An authoritative server publishes the records for a particular zone and returns authoritative information within its scope. I would draw arrows from the resolver to each relevant authority and have each referral return to the resolver. Then I would identify the service that answered my actual tool query, because a recursive response and a direct authoritative exchange serve different diagnostic purposes.
Does every browser navigation cause a new root-server query?
The browser and local name service can reuse information, and a recursive resolver can reuse an address or an earlier delegation. Even when it needs fresh data, it can often ask a more specific authority using cached name-server information. A cold-cache teaching diagram describes one way to learn the path. I would distinguish that explanation from the exchanges that actually happened for the user.
Why might lowering a TTL just after a deployment fail to shorten the observed delay?
A resolver might have already cached a value with the prior longer TTL. Changing the published TTL applies to later fetches. Updating the existing authoritative data does not edit copies held by other resolvers. I would compare the authoritative result with the client's normal recursive response, and document the remaining cache lifetimes that we can observe. A planned change can lower the TTL sufficiently early and retain a working prior endpoint as appropriate.
How do you distinguish NXDOMAIN from a name that has no AAAA data?
Check the requested name, returned status, applicable records and authority section using full output. NXDOMAIN signals name nonexistence in its applicable context. An existing name with no AAAA may return NOERROR with no AAAA data. It could still have a useful A result. Referrals can also lack a final answer, so I read the full context and query source. An empty short form alone leaves those possibilities open.
What does SERVFAIL tell you that NXDOMAIN does not?
SERVFAIL means the responding server failed to complete the resolution. It may be related to unreachable authorities, bad delegation, validation or another failure. A client timeout is another observation often worth recording separately. NXDOMAIN conveys a negative DNS answer about a name. I would trace the relevant authority and validation when the resolver reports failure, while checking the exact owner when the answer says it is missing.
How do you verify a browser site after DNS answers have changed?
First check the intended name and address type in the applicable authority and chosen resolver. Then make an authorized request with the intended hostname, protocol, port and path. For ordinary HTTPS the client must verify the appropriate endpoint identity before HTTP, and a named response should contain a recognizable expected marker. This compares the locator with actual application behavior and can reveal a fallback or stale web body after correct DNS results.
Predict the resolver result
A resolver gets a 120-second A answer at time zero. The authority changes it at 30. In the simple model, what does that same resolver answer at 60?
Answer and reasoning
It returns the stored old answer with 60 seconds left, since the initial entry is still valid at time 60. A resolver with no matching cache entry can ask the authority and learn the new answer at the same moment.
The root service points your resolver to the intended top-level name servers. Does that observation contain the site address?
Answer and reasoning
In this example the result is a referral that tells the resolver whom to ask next. The relevant authority later publishes the actual website address. Some supporting server addresses in a referral help the next query and have a different purpose.
A query prints NOERROR with no AAAA entry while an A lookup succeeds. What distinction is relevant?
Answer and reasoning
The name can exist while the requested IPv6 record type is missing. Read the whole DNS result to distinguish the lack of applicable data from a referral. The working IPv4 answer does not supply IPv6 information.
In the lab, the new name is published at 30 and a prior negative expires at 65. Which result appears at 40 in the same resolver?
Answer and reasoning
It still reports the cached negative answer for that question until its model lifetime expires. The authoritative change happens at 30, while the cache refresh happens when the old observation becomes unusable and another query arrives.
A direct trace is blocked on a corporate network while the configured resolver answers successfully. What two observations should you keep?
Answer and reasoning
Record that the normal resolver returned the specific answer, and that this diagnostic path could not query the authoritative hierarchy directly. The two tools attempt different exchanges. Use the authorized resolver observation and request additional evidence through the approved network if necessary.
Cards for a lookup notebook
Identify the exact question
Write the DNS name, record type and responding server. Then read the status and relevant response sections.
Referrals lead toward authority
The resolver uses referrals to decide whom to ask next. A positive cache can bypass part of the walk.
Remaining time belongs to one observation
A TTL reports cache lifetime information. Resolvers can learn the same data at different times and refresh independently.
Three different negative observations
Name absence, absence of this record type and a failed attempt to resolve the name need distinct evidence and actions.
Continue past the DNS answer
Identify the destination address, establish the connection and appropriate TLS identity, then test the intended HTTP route and expected body.
Official references
- IETF terminology for referrals, recursive and authoritative DNS
- DNS concepts and resolution model
- DNS message fields, statuses and transport
- Negative DNS caching, name absence and type absence
- Caching DNS resolution failures
- Stale cached data under refresh failure
- Query name minimization
- DNS transport over TCP
- AWS public resolution and authoritative example
- ISC dig options and output
- AWS VPC recursive resolver and forwarding roles
- IANA example domain names