Basics of the Domain Name System (DNS) By : AMMY- DRISS Mohamed Amine KADDARI Zakaria MAHMOUDI Soufiane Oujda Med I University National College of Applied Sciences Computer Engineering Supervised by: Mr. ABDALAOUI Mohammed 1 DNS
Introduction to DNS DNS Benefits Key Components of DNS Name Resolution Process 2 DNS
Introduction to DNS DNS Benefits Key Components of DNS Name Resolution Process 3 DNS
The DNS is… The Domain Name System is a distributed database system that can serve as the foundation for Name resolution in a TCP/IP network. 4 DNS
DNS VS File System 5 DNS
yahoo.com.au. C:\windows\system32\drivers \ A “.” is used as separator A “\” is used as separator Start Here DNS VS File System 6 DNS
Introduction to DNS DNS Benefits Key Components of DNS Name Resolution Process 7 DNS
DNS Benefits 8 DNS
DNS Benefits Convenience Names are easier to remember Convenience Names are easier to remember 9 DNS
DNS Benefits Convenience Names are easier to remember Convenience Names are easier to remember Consistency Server names can remain constant Consistency Server names can remain constant 10 DNS
DNS Benefits Convenience Names are easier to remember Convenience Names are easier to remember Consistency Server names can remain constant Consistency Server names can remain constant Simplicity One naming convention Simplicity One naming convention 11 DNS
Scalability Scalability 12 DNS Reliability Reliability Dynamicity Dynamicity Other benefits
Reliability Data is replicated ◦Data from master is copied to multiple slaves Clients can query ◦Master server ◦Any of the copies at slave servers Clients will typically query local caches DNS protocols can use either UDP or TCP ◦If UDP, DNS protocol handles retransmission, sequencing, etc. 13 DNS
Dynamicity Database can be updated dynamically ◦Add/delete/modify of any record Modification of the master database triggers replication 14 DNS
Introduction to DNS DNS Benefits Key Components of DNS Name Resolution Process 15 DNS
The Name Space The name space is the structure of the DNS database An inverted tree with the root node at the top Each node has a label The root node has a null label, written as “” 16 DNS
Domain Names A domain name is the sequence of labels from a node to the root, separated by dots (“.”s), read left to right ◦The name space has a maximum depth of 127 levels ◦Domain names are limited to 255 characters in length A node’s domain name identifies its position in the name space 17 DNS
Delegation Administrators can create subdomains to group hosts ◦According to geography, organizational affiliation or any other criterion An administrator of a domain can delegate responsibility for managing a subdomain to someone else ◦But this isn’t required The parent domain retains links to the delegated subdomain ◦The parent domain “remembers” who it delegated the subdomain to 18 DNS
Delegation Creates Zones Each time an administrator delegates a subdomain, a new unit of administration is created ◦The subdomain and its parent domain can now be administered independently ◦These units are called zones ◦The boundary between zones is a point of delegation in the name space Delegation is good: it is the key to scalability 19 DNS
nominum.com domain nominum.com zone ams.nominum. com zone rwc.nominum.c om zone Dividing a Domain into Zones 20 DNS
The “MX” Record An MX record defines the mail servers for a particular domain Mail eXchange records hold the name of hosts, and their priorities, able to deliver mail for the domain. Eg. The record: ensao.com.maMX10mail In the ensao.com.au domain, defines the host mail to be the priority 10 mail server for the “ensao.com.ma” domain 21 DNS
The “NS” Record An NS record defines the authoritative Name servers for the domain. The “Name Server” records also define the name servers of children domains Eg. The record: internalNSns1.hosting.com.ma In the ensao.com.ma domain, defines the host “ns1.hosting.com.ma” to be a name sever for the “internal.ensao.com.ma” sub-domain 22 DNS
What is a Name Sever? Server responsible for answering DNS queries Exists at all levels of hierarchy Authoritative name servers hold part of the DNS database One name server can serve more then one zone Many name servers “should” serve the same zone Some name servers are authoritative for certain zones 23 DNS
Types of Name Servers Two main types of servers ◦Authoritative – maintains the data Master – where the data is edited Slave – where data is replicated to ◦Caching – stores data obtained from an authoritative server ◦The most common name server implementation (BIND) combines these two into a single process Other types exist… No special hardware necessary 24 DNS
Name Server Architecture You can think of a name server as part: ◦database server, answering queries about the parts of the name space it knows about (i.e., is authoritative for), ◦cache, temporarily storing data it learns from other name servers, and ◦agent, helping resolvers and other name servers find data that other name servers know about 25 DNS
Introduction to DNS DNS Benefits Key Components of DNS Name Resolution Process 26 DNS
Accessing a web page You type into your web browser and hit enter. What happens now? 27 DNS
Step 1: Your PC sends a resolution request to its configured DNS Server, typically at your ISP. Tell me the Address of “ 28 DNS
Step 2: Your ISPs recursive name server starts by asking one of the root servers predefined in its “hints” file. Tell me the Address of “ I don’t know the address but I know who’s authoritative for the ”com” domain ask them 29 DNS
Step 3: Your ISPs recursive name server then asks one of the “com” name servers as directed. Tell me the Address of “ I don’t know the address but I know who’s authoritative for the ”google.com” domain ask them 30 DNS
Step 4: Your ISPs recursive name server then asks one of the “google.com” name servers as directed. Tell me the Address of “ The Address of is DNS
Step 5: ISP DNS server then send the answer back to your PC. The DNS server will “remember” the answer for a period of time. The Address of is DNS
Step 6: Your PC can then make the actual HTTP request to the web server. Here it is! Send me the web page 33 DNS
The actual web request DNS Summary 34 DNS
Sending an DNS is not just used in HTTP protocol (web pages) DNS is involved in almost every protocol in use on the internet Next example is how DNS facilitates the transfer of electronic mail. 35 DNS
Step 1: Your PC sends the to its configured outbound mail server. A DNS request similar to the previous example is required to find the address of the mail server. Please send this message to 36 DNS
Step 2: Your mail server follows the same intensive process to find the authoritative servers for “example.com”. Tell me the name servers for “ensao.com” Here are the name servers for “ensao.com” 37 DNS
Step 3: Ask the “example.com” name server for the list of “Mail eXchangers (MX) for that domain. Tell me the MX’s for “ensao.com” The MXs are mx10.ensao.com and mx20.backmail.com 38 DNS
Step 4: Select a Mail server and deliver the mail. Here is some mail for the “ensao.com” domain Mail accepted for delivery 39 DNS
Summary DNS is integral part in most protocols used on the internet Makes the internet human friendly for all of us It is the world largest distributed database system Fits the international model perfectly In simple terms is a mapping between names and IP addresses 40 DNS
Webliography: o o 41 DNS
Thank you 42 DNS
Questions? 43