0% found this document useful (0 votes)
12 views45 pages

Understanding the Domain Name System

The document provides an overview of the Domain Name System (DNS), explaining its decentralized and hierarchical structure, including local DNS servers and query types (recursive and iterative). It details how DNS records are created and stored, including various types such as A, NS, CNAME, and MX records, and describes the process of registering a domain name through a registrar. Additionally, it emphasizes the importance of DNS caching and the role of authoritative DNS servers in resolving domain names to IP addresses.

Uploaded by

kimon
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views45 pages

Understanding the Domain Name System

The document provides an overview of the Domain Name System (DNS), explaining its decentralized and hierarchical structure, including local DNS servers and query types (recursive and iterative). It details how DNS records are created and stored, including various types such as A, NS, CNAME, and MX records, and describes the process of registering a domain name through a registrar. Additionally, it emphasizes the importance of DNS caching and the role of authoritative DNS servers in resolving domain names to IP addresses.

Uploaded by

kimon
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

1.11.

2024

Domain Name System


Eleftheria Psilou
psilou@[Link]
Domain Name System

[Link]

[Link]
DNS is decentralized

A simple design for this process would have been one DNS server
containing all mappings
Issues with this idea:
- Single point of failure
- Traffic volume
- Distant database

That’s why they made DNS to be distributed!


The hierarchy of the DNS servers

1. root
2. top-level domain (TLD)
3. authoritative
Local DNS Server

Not strictly in the hierarchy.

Each ISP has a local DNS Server, usually close to the host.

When a host makes a DNS query, it is sent to the local DNS server, which
then forwards it into the DNS server hierarchy.
Example
[Link]
wants to get the
IP address of
[Link]
[Link]?
[Link]?

[Link]?
[Link]?

(TLD1) [Link]
(TLD2) [Link]
… …

[Link]?
[Link]?
[Link]?

[Link]?
[Link]?
[Link]?

[Link]
([Link])
[Link]?
[Link]?

[Link]?
[Link]?
[Link]?

[Link]?
[Link]?

[Link]
([Link])
[Link]?

[Link]
([Link])
Query types
Recursive
The DNS server fully resolves the domain on
behalf of the client, querying other servers as
needed, and returns the final IP address.

Iterative
The replies are directly returned to the server
initially querying, and the server keeps querying
respecting the order of the DNS hierarchy until
the hostname is resolved
DNS Caching
When a DNS server receives a DNS reply containing a mapping, it can cache the
mapping in its local memory, temporarily.

This way, when a new request arrives for that mapping, it can provide the required
information without contacting another DNS server.

DNS servers discard cached info after a period of time (often set to 2 days)
DNS Records
DNS servers store resource records (RRs)

Each DNS reply message carries one or more resource records.

(Name, Value, Type, TTL)


DNS Records
(Name, Value, Type, TTL)

Type Name Value

A Hostname IP of the hostname

Hostname of authoritative
NS Domain (e.g. [Link])
DNS server

CNAME Alias Hostname True hostname

MX Alias Hostname True hostname (mail server)


DNS Records
Authoritative DNS server for hostname H contains a Type A record for H.

Not authoritative DNS server for hostname H contains

- Type NS record for the domain of H


- Type A record with the IP address of the server in the Value field of the NS
record
DNS Records - Example
Authoritative DNS server for hostname H contains a Type A record for H.
Not authoritative DNS server for hostname H contains
- Type NS record for the domain of H
- Type A record with the IP address of the server in the Value field of the NS record

.edu TLD DNS Server [Link] DNS Server

Name Value Type Name Value Type

[Link] [Link] NS [Link] [Link] A

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link]? [Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link]? [Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link]? [Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

[Link]? .edu TLD DNS Server

[Link] Name Value Type

[Link] [Link] NS

[Link] [Link] A

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

.edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A
[Link]?

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

.edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A
[Link]?

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

.edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A
[Link]?

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Records - Example

.edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A
[Link]?

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A [Link]


DNS Records - Example

.edu TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A
[Link]? [Link]

[Link]

[Link] DNS Server

Name Value Type

[Link] [Link] A
DNS Messages
Query

Reply
DNS Messages
Inserting Records
How is the DNS server filled in the first place?
Inserting Records - Example
You have created a startup, “Network Utopia”
Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.


Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.


Registrar: A commercial entity that verifies the uniqueness of the domain name, enters the
domain name into the DNS database, in exchange for a small fee.
Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.


Registrar: A commercial entity that verifies the uniqueness of the domain name, enters the
domain name into the DNS database, in exchange for a small fee.

You must, of course, also provide the names and addresses of your primary and
secondary authoritative DNS servers.
Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.


Registrar: A commercial entity that verifies the uniqueness of the domain name, enters the
domain name into the DNS database, in exchange for a small fee.

You must, of course, also provide the names and addresses of your primary and
secondary authoritative DNS servers.

The registrar will enter a Type NS and a Type A record into the TLD .com servers for
your primary and secondary DNS servers
Inserting Records - Example
You have created a startup, “Network Utopia”
First, you register the domain name [Link] at a registrar.
The registrar will enter a Type NS and a Type A record into the TLD .com servers for
your primary and secondary DNS servers.
.com TLD DNS Server

Name Value Type

[Link] [Link] NS

[Link] [Link] A

[Link] [Link] NS

[Link] [Link] A
Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.

You’ll also have to make sure that the Type A RR for you web server
[Link] and the Type MX RR for your mail server
[Link] are in your authoritative DNS server.
Inserting Records - Example
You have created a startup, “Network Utopia”

First, you register the domain name [Link] at a registrar.

You’ll also have to make sure that the Type A RR for you web server
[Link] and the Type MX RR for your mail server
[Link] are in your authoritative DNS server.

Your Primary Authoritative DNS Server (DNS1)

Name Value Type

[Link] [Link] A

[Link] [Link] MX
Quiz
[Link]

You might also like