➢Each computer in Internet is known using an IP address ➢People can remember words better than number ➢Each server’s IP has its equivalent hostname ➢What if the IP of a server is changed? Application Layer Protocol: DNS • Domain Name Service (DNS): 1. DNS provides a core Internet function, translating hostnames to their underlying IP addresses, for user applications and other software in the Internet. The DNS protocol defines an automated service that matches resource names with the required numeric network address ▪ DNS uses a large number of name servers, organized in a hierarchical fashion and distributed around the world. No one name server has all of the mappings for all of the hosts in the internet. Instead, the mappings are distributed across the name servers. There are three types of name servers: 1. Local name server* (Local DNS server) 2. Root name servers 3. Top-level name server 4. Authoritative name servers
*Name server and DNS server mean the same thing
DNS Hierarchy DNS cont. 1. Root name servers: A root server contains information about the root and top-level domains, When a local name server cannot immediately satisfy a query from a host (because it does not have a record for the hostname being requested), the local name server behaves as a DNS client and queries one of the root name servers. 2. Local name server: Each ISP - such as a university, an academic department, an employee's company or a residential ISP - has a local name server (also called a default name server or local DNS server). When a host issues a DNS query message, the message is first sent to the host's local name server. The IP address of the local name server is typically configured by hand in a host. 3. Authoritative name servers: Every website is registered with an authoritative name server. Typically, the authoritative name server for a website is a name server in the website's local ISP. Authoritative DNS nameservers are responsible for providing answers to recursive DNS nameservers about where specific websites can be found. These answers contain important information for each domain, like IP addresses. Internet Domain Names ➢ As an example, consider a namespace with names of the form: – local. site • where site is the site name authorized by the central authority, local is the part of a name controlled by the site, and (".") is a delimiter used to separate them. ➢ adding a group subdivision to names already partitioned by site produces the following name syntax: • local. group. site Internet Domain Names • Example: cs .aiub . edu • contains three labels: cs, aiub, and edu. Any suffix of a label in a domain name is also called a domain. In the above example the lowest level domain is cs . aiub. edu, (the domain name for the Computer Science Department at AIUB), the second level domain is aiub. edu (the domain name for AIUB University), and the top- level domain is edu (the domain name for educational institutions). As the example shows, domain names are written with the local label first and the top domain last. Hierarchy of name servers Top-level domain
Second-level domain(organization name)
A central body determines
Upto second level-domain Recursive Resolution
Iterative Resolution Recursive Resolution
Iterative Resolution Different types of DNS queries
• DNS queries can be classified according the manner in which a
complete request is processed. Generally queries can be classified as follows. 1. Recursive query: A recursive query is a kind of query, in which the DNS server, who received the sender’s query will do all the job of fetching the answer, and giving it back to the sender. During this process, the DNS server might also query other DNS server's in the internet of the sender’s behalf, for the answer. It is done from host to local DNS server 2. Iterative query OR Nonrecursive query: In an iterative query, the name server, will not go and fetch the complete answer for the sender’s query, but will give back a referral to other DNS server's, which might have the answer. It is done between Local DNS servers to other DNS servers (such as Root server, TLD, authoritative DNS servers..)