Sunteți pe pagina 1din 29

DOMAIN NAME SYSTEM(DNS)

Overview
Introduction Name Space Domain Name Space. Name Resolution Questions

Introduction
URL(Uniform Resource Locator)
http://HostAddress The host address is where a Web site can be found . Host Address can be : 1. The IP Address 199.239.136.200 or 2. The Domain Name www.xyz.com

Introduction contd..

Much easier to remember the domain name than a IP address Problem


Network only understands The IP Address it dont understand domain name .

Introduction contd ..

So DNS is A client-server application that maps domain names into their corresponding IP addresses with the help of name servers. Mapping domain names into their corresponding IP addresses is called name resolution or Address Resolution or name translation or name mapping

Domain Name System(DNS) Comprises Of


Name Client: Name client requests a name server to resolve the given domain name to its IP address
Name Server: name server resolves the given name to its IP address It listens to port no 53 of UDP Distributed Name Database name-to-IP address mappings are stored in database associated with a name server

Types Of Name Servers


Root Name Servers
. Servers
As of February 2013, there are 13 root name servers in the world

Intermediate Name Server : Also known as Top Level Name Server Authoritative name server:
Stores hosts IP address, name . So can perform name resolution

Local name servers:


Each ISP, company has

name server known as Local NS

NAME SPACE

To be unambiguous, the names assigned to machines must be carefully selected from a name space with complete control over the binding between the names and IP addresses

Name Space contd ..

Name Space

Flat Name Space


Distributed Name Space

Hierarchical Name Space

Flat Name Space


A name is assaigned to an adress.

A name in this space is asequence of

chracter without steucter.

Distributed Name Space

Hierarchical Name Space


Each name is made of several parts.
First

part define the nature of the organization. part can define the name of an organization. part can define departments in the organization.

Second

Third

Domain Name Space


Domain name for a host is the sequence of lables that lead from the host to the top of Inverted Tree.
Domain name is case insensitive.

The tree can have atmost 128 levels(0-127)


Each Level can have atmost 63 chracters Domain name can have atmost 255 characters The Internet is divided into more than 200 top-level domains

Naming a Domain

vs

Naming a Directory
C:

Start Here

com

au

net

Program Files

Windows

Temp

org

com

net

id

Cache

System32

Fonts

Media

microsoft

google

yahoo

Start Here

drivers

dllcache

spool

yahoo.com.au.
A . is used as separator

C:\windows\system32\drivers\

A \ is used as separator

Label &Domain name


Lavel Each node in the tree has a level.
Lavel is a string with a maximum of 63 characters.

Domain Name
Each node in the tree has a domain name.

Label &Domain name contd ..

FQDN & PQDN


Fully Qualified Domain Name(FQDN)
It is domain name consisting of labels beginging with

host going back through each level to the root node. In FQDN , a lavel is terminated by a null string. Partially Qualified Domain Name
It is a domain name that does not include all the lavels

between the host and the root node

FQDN & PQDN contd ..

Name Resolution
Mapping domain names into their corresponding IP addresses.
This technique of Name Resolution is of two types :

Recursive resolution:-Recursive servers know how to ask others for information 2) Iterative resolution:- Iterative servers dont know how to ask others for information they can only answer if they have information in its cache or in its database
1)

Two things to keep in mind


1
Root NS Top Level NS Authoritative NS HOST

Query

Local NS

Finally Host will get IP Address through Local NS

Recursive Resolution

Recursive Resolution Continues..


1) Host A queries the Internet Service Provider's Name Server for the IP address of host sales.xyzcompany.com 2) If Internet Service Provider's Name Server does not have the answer in its cache or in its database, it will query the root name server for the IP address of host sales.xyzcompany.com 3) If the root name server does not have the answer in its cache or in its database, it will query Top Level Domain Name Server (.COM In The Example Above) for the IP address of host sales.xyzcompany.com 4) If Top Level Domain Name Server does not have the answer in its cache or in its database, it will contact Authoritative Name Server 5) Authoritative Name Server will return the answer to Top Level Domain Name Server 6) Top Level Domain Name Server will return the answer to the root name server 7) The root name server will return the answer to Internet Service Provider's Name Server 8) Internet Service Provider's Name Server will return the answer to host A

Iterative Resolution

Iterative Resolution Continues..


1. Host A queries the Internet Service Provider's name server for the IP address of sales.xyzcompany.com 2.

3.

4. 5.

6. 7.

8.

If ISP name server does not have the answer in its cache or in its database, it will contact root name server for the IP address of host sales.xyzcompany.com If the root name server does not have the answer in its cache or in its database, it will reply to ISP name server with the IP address of Top Level Domain Name Server (.COM In The Example Above) ISP name server will query Top Level Domain Name Server for the IP address of host sales.xyzcompany.com If Top Level Domain Name Server does not have the answer in its cache or in its database, it will reply to ISP name server with the IP address of the Authoritative Name Server ISP name server will query Authoritative Name Server for the IP address of host sales.xyzcompany.com Since Authoritative Name Server will have the address so it will reply ISP name server with the IP address for host sales.xyzcompany.com Finally ISP name server returns IP address to host A.

Questions???
Q.1 i.e myhost.cit.cornell.edu Can we have more than one IP address for one domain name? 128.253.180.25

128.253.180.26

Q.2 Can we have more than one domain name for one IP address?

Q.3 Is this possible ?


abc.cit.cornell.edu

128.253.180.25

xyz.cit.cornell.edu

Ans1. Yes , we can have more than one IP address for one
domain name . This thing is managed by A(Address) record. It is known as round-robin DNS . DNS will cycle from one IP address to the next each time the domain name is called.

A record
An A (Address) record translates a domain name to an IP address
myhost.cit.cornell.edu
myhost.cit.cornell.edu abc.cit.cornell.edu

IN A
IN A CNAME

128.253.180.25
128.253.180.26 myhost.cit.cornell.edu

xyz.cit.cornell.edu

CNAME

myhost.cit.cornell.edu

Ans 2. No, we cannot have more than one domain name for one IP address. Ans 3. Yes, we can have like this
abc.cit.cornell.edu

128.253.180.25

xyz.cit.cornell.edu

We have one domain name and multiple aliases for that one domain name. This thing is managed by CNAME

CNAME(canonical name)
The CNAME maps the aliases (different name of single host) to the "official" name of a host. The official name is stored in the A record.
myhost.cit.cornell.edu myhost.cit.cornell.edu abc.cit.cornell.edu xyz.cit.cornell.edu IN A IN A CNAME CNAME 128.253.180.25 128.253.180.26 myhost.cit.cornell.edu myhost.cit.cornell.edu

References
Data Communications and Networking by Behrous A.Forouzan .

http:// www.wikipedia.org http://compnetworking.about.com http://www.iana.org

THANK YOU

S-ar putea să vă placă și