chapter 25

29
25.1 Chapter 25 Domain Name System Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Upload: faisal-mehmood

Post on 20-Jun-2015

363 views

Category:

Education


1 download

DESCRIPTION

Domain Name System

TRANSCRIPT

Page 1: Chapter 25

25.1

Chapter 25

Domain Name System

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Page 2: Chapter 25

25.2

Figure 25.1 Example of using the DNS service

Page 3: Chapter 25

25.3

25-1 NAME SPACE25-1 NAME SPACE

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

Flat Name SpaceHierarchical Name Space

Topics discussed in this section:Topics discussed in this section:

Page 4: Chapter 25

25.4

25-2 DOMAIN NAME SPACE25-2 DOMAIN NAME SPACE

To have a hierarchical name space, a domain name To have a hierarchical name space, a domain name space was designed. In this design the names are space was designed. In this design the names are defined in an inverted-tree structure with the root at defined in an inverted-tree structure with the root at the top. The tree can have only 128 levels: level 0 the top. The tree can have only 128 levels: level 0 (root) to level 127. (root) to level 127.

LabelDomain NameDomain

Topics discussed in this section:Topics discussed in this section:

Page 5: Chapter 25

25.5

Figure 25.2 Domain name space

Page 6: Chapter 25

25.6

Figure 25.3 Domain names and labels

Page 7: Chapter 25

25.7

Figure 25.4 FQDN and PQDN

Page 8: Chapter 25

25.8

Figure 25.5 Domains

Page 9: Chapter 25

25.9

25-3 DISTRIBUTION OF NAME SPACE25-3 DISTRIBUTION OF NAME SPACE

The information contained in the domain name space The information contained in the domain name space must be stored. However, it is very inefficient and also must be stored. However, it is very inefficient and also unreliable to have just one computer store such a huge unreliable to have just one computer store such a huge amount of information. In this section, we discuss the amount of information. In this section, we discuss the distribution of the domain name space. distribution of the domain name space.

Hierarchy of Name ServersZoneRoot ServerPrimary and Secondary Servers

Topics discussed in this section:Topics discussed in this section:

Page 10: Chapter 25

25.10

Figure 25.6 Hierarchy of name servers

Page 11: Chapter 25

25.11

Figure 25.7 Zones and domains

Page 12: Chapter 25

25.12

A primary server loads all information from the disk file; the secondary server

loads all information from the primary server.

When the secondary downloadsinformation from the primary, it is called

zone transfer.

Note

Page 13: Chapter 25

25.13

25-4 DNS IN THE INTERNET25-4 DNS IN THE INTERNET

DNS is a protocol that can be used in different DNS is a protocol that can be used in different platforms. In the Internet, the domain name space platforms. In the Internet, the domain name space (tree) is divided into three different sections: generic (tree) is divided into three different sections: generic domains, country domains, and the inverse domain.domains, country domains, and the inverse domain.

Generic DomainsCountry DomainsInverse Domain

Topics discussed in this section:Topics discussed in this section:

Page 14: Chapter 25

25.14

Figure 25.8 DNS IN THE INTERNET

Page 15: Chapter 25

25.15

Figure 25.9 Generic domains

Page 16: Chapter 25

25.16

Table 25.1 Generic domain labels

Page 17: Chapter 25

25.17

Figure 25.10 Country domains

Page 18: Chapter 25

25.18

Figure 25.11 Inverse domain

Page 19: Chapter 25

25.19

25-5 RESOLUTION25-5 RESOLUTION

Mapping a name to an address or an address to a Mapping a name to an address or an address to a name is called name-address resolution.name is called name-address resolution.

ResolverMapping Names to AddressesMapping Addresses to NamesRecursive ResolutionCaching

Topics discussed in this section:Topics discussed in this section:

Page 20: Chapter 25

25.20

Figure 25.12 Recursive resolution

Page 21: Chapter 25

25.21

Figure 25.13 Iterative resolution

Page 22: Chapter 25

25.22

25-6 DNS MESSAGES25-6 DNS MESSAGES

DNS has two types of messages: query and response. DNS has two types of messages: query and response. Both types have the same format. The query message Both types have the same format. The query message consists of a header and question records; the consists of a header and question records; the response message consists of a header, question response message consists of a header, question records, answer records, authoritative records, and records, answer records, authoritative records, and additional records.additional records.

HeaderTopics discussed in this section:Topics discussed in this section:

Page 23: Chapter 25

25.23

Figure 25.14 Query and response messages

Page 24: Chapter 25

25.24

Figure 25.15 Header format

Page 25: Chapter 25

25.25

25-7 TYPES OF RECORDS25-7 TYPES OF RECORDS

As we saw in Section 25.6, two types of records are As we saw in Section 25.6, two types of records are used in DNS. The question records are used in the used in DNS. The question records are used in the question section of the query and response messages. question section of the query and response messages. The resource records are used in the answer, The resource records are used in the answer, authoritative, and additional information sections of authoritative, and additional information sections of the response message.the response message.

Question RecordResource Record

Topics discussed in this section:Topics discussed in this section:

Page 26: Chapter 25

25.26

25-8 REGISTRARS25-8 REGISTRARS

How are new domains added to DNS? This is done How are new domains added to DNS? This is done through a registrar, a commercial entity accredited by through a registrar, a commercial entity accredited by ICANN. A registrar first verifies that the requested ICANN. A registrar first verifies that the requested domain name is unique and then enters it into the domain name is unique and then enters it into the DNS database. A fee is charged.DNS database. A fee is charged.

Page 27: Chapter 25

25.27

25-9 DYNAMIC DOMAIN NAME 25-9 DYNAMIC DOMAIN NAME SYSTEM (DDNS) SYSTEM (DDNS)

The DNS master file must be updated dynamically. The DNS master file must be updated dynamically. The The Dynamic Domain Name System (DDNS)Dynamic Domain Name System (DDNS) therefore therefore was devised to respond to this need. In DDNS, when a was devised to respond to this need. In DDNS, when a binding between a name and an address is determined, binding between a name and an address is determined, the information is sent, usually by DHCP to a primary the information is sent, usually by DHCP to a primary DNS server. The primary server updates the zone. The DNS server. The primary server updates the zone. The secondary servers are notified either actively or secondary servers are notified either actively or passively. passively.

Page 28: Chapter 25

25.28

25-10 ENCAPSULATION25-10 ENCAPSULATION

DNS can use either UDP or TCP. In both cases the DNS can use either UDP or TCP. In both cases the well-known port used by the server is port 53. UDP is well-known port used by the server is port 53. UDP is used when the size of the response message is less than used when the size of the response message is less than 512 bytes because most UDP packages have a 512-byte 512 bytes because most UDP packages have a 512-byte packet size limit. If the size of the response message is packet size limit. If the size of the response message is more than 512 bytes, a TCP connection is used. more than 512 bytes, a TCP connection is used.

Page 29: Chapter 25

25.29

DNS can use the services of UDP or TCP using the well-known port 53.

Note