Blog :: General

Overview of DNS Protocol : Part 2 of 3

This is part 2 of our 3 part series which provides an overview of the DNS protocol.  Below are a few other terms you may have run into. There definitions are as follows but, you should read part 1 of the Overview of DNS Protocol first.

Hostname : is a label that is assigned to a device connected to a computer network and that is used to identify the device in various forms of electronic communication such as the World Wide Web, e-mail or Usenet. Hostnames may be simple names consisting of a single word or phrase, or they may be structured (e.g. myhost). A host name can be a FQDN.

Parent Domain name: example.com is the parent of myhost.example.com which is the parent of not.myhost.example.com

Child Domain name: not.myhost.example.com is the child of myhost.example.com which is the child of example.com. Child Domains = subdomains.

Subdomain: west.example.com and east.example.com are subdomains of the example.com domain. Also, go.west.example.com is a subdomain of west.example.com.

CNAME (canonical name) records are handled specially in the domain name system, and have several restrictions on their use. When a DNS resolver encounters a CNAME record while looking for a regular resource record, it will restart the query using the canonical name instead of the original name. E.g. bar.example.com is an alias for the canonical name (CNAME) foo.example.com. A client will request bar.example.com and the answer will be foo.example.com.

QUESTION: What if the DNS the computer uses doesn’t have the IP address of the website you want to visit?

Answer: If the local DNS cannot respond with an ‘authoritative’ reply because it doesn’t know the immediate answer after checking its local cache, the DNS will ask another DNS. For this reason, we have to discuss recursive and iterative DNS queries. In the figure above, a non-recursive query example is given. If however, the DNS still fails after recursion, the client can then ask the secondary DNS if one has been configured.

DNS Non-Recursive Query: The DNS server provides a record for a domain for which it is authoritative itself, or it provides a partial result without querying other servers.

DNS Recursive Query: The DNS server will fully answer the query (or give an error) by querying other name servers as needed. DNS servers are not required to support recursive queries. In other words, if a name server cannot answer a query because it does not contain an entry for the host in its database, it MAY recursively query name servers higher up in the hierarchy.

Recursive DNS Resolver (RDNS): Example: if a client wants to know the address for “www.example.com”, it will send, to a recursive caching name server, a DNS request stating “I would like the IPv4 address for ‘www.example.com’.” The recursive name server will then query authoritative name servers until it gets an answer to that query (or return an error if it’s not possible to get an answer)–in this case 192.0.43.10. By default, most DNS configurations support recursion and for this reason, sometimes the client making the request is referred to as a Stub DNS Resolver.

DNS Stub Resolver: Communicate with a single name server and rely on a recursive name server to perform the work lookup work. Read more about the DNS Resolver.

How the DNS Protocol works
Iterative Query: The DNS Resolver (i.e. client) attempts to contact additional DNS servers to resolve a name. When a client does so, it uses separate and additional nonrecursive queries based on referral answers from servers. An iterative request tells the DNS server that the client expects the best answer the DNS server can provide immediately, without contacting other DNS servers. See How Iteration Works.

Iterative DNS request

DNS Root Servers: A network of hundreds of servers all over the world. They are configured in the DNS root zone as 13 named authorities. To reach one of these 13 (A-M), a DNS would use a anycast address. The named authority is a bunch of servers that the single request is sent to via an anycast address. To date, there are 504 addreses behind the 13 named authorities which are also known as root servers.

Anycast: Through the use of BGP, anycast allows multiple, identical, globally deployed DNS servers to advertise the same IP address. For all intents and purposes, the same server exists in dozens or hundreds of places simultaneously. When an Internet user looks up your domain name, they find the Anycast instance topologically closest to themselves.

Part 3 of the Overview of DNS Protocol.