Domain Name Service
1. What is a Domain?
2. What is DNS?
3. Who is InterNIC?
4. The DNS Structure.
5. How does DNS work?
6. How does DNS really work? (Yes, I am a big boy and can handle
the technical details.)
What is a Domain?
In general, a domain is an area of control or a sphere of knowloedge. In the internet world, domains are areas of knowledge about a group of names and addresses. Domains contain information about email, hostnames, websites, where the domain is hosted, and other information. Domains were invented to help people get around better on the internet. Domains enable users to use "friendly" names for machines on the internet.In more specific terms, a domain locates a machine or host on the internet. For example, the hostname www.yahoo.com indicates the domain name of yahoo.com with a hostname of www and an address of 204.71.200.75. From this example. we can extrapolate further to say that yahoo is the name of a commercial organization in the com hierarchy and that www is the hostname in question.
What is DNS?
The domain name system (DNS) is the way that Internet domain names are located and translated into IP (Internet Protocol) addresses. A domain name is a meaningful and "friendly" name for an Internet address. Because maintaining a central list of domain name/IP address mappings would be impractical, the list of domain names are distributed across many servers so that no one server will have to know all information about all the domains on the Internet. Each domain name server only must be knowledgable, or authoritative, for those domains that have been registered to it. The rest of the domains can be found by using what are called root name servers, which maintain a list of all the domains and where information about those domains can be found. These servers are maintained in large part by an organization called InterNIC.Who is InterNIC?
Unitl recently, InterNIC (Internet Network Information Center), a cooperative activity between the U.S. government and Network Solutions, Inc., was the organization responsible for registering and maintaining the com, net, org , gov, and edu top-level domain names on the World Wide Web. This organization maintained a database for the com, net, and org top-level domains and where information could be found for these domains. As a result of some recent legislation passed in October of 1998, other companies will now be offering the services that InterNIC had alone controlled.The DNS structure
Domain names are constructed hierarchichally, that is, each section of a host name is listed in hierarchical order The labels go from most specific to least specific. Labels can be up to 63 characters long and are case insensitive. A maximum length of 255 characters is allowed. Labels must start with a letter and can only consist of letters, digits, and hyphens.DNS addresses can be relative or fully qualified. A fully qualified address includes all the labels and is globally unique. A relative address can be converted by appending the local domain information. For example, www.ringofsaturn.com is a fully qualified domain name, while www is relative. The www label will mean different things depending on where it is referenced. Strictly speaking, fully qualified domains are preferred as less errors will occur when they are used.
The final most significant label of a fully qualified name will fall into one of three categories:
- arpa
- This is a special first level domain used for reverse translation,
ie, going from number to name. As stated earlier, domains are listed
in a hierarchical manner from most specific to least specific. Thus,
the reverse dns for 206.50.17.51 will look like this:
- Three Letter Top-Level Domains
51.17.50.206.in-addr.arpa name = ringofsaturn.com
Notice that the entry is in reverse order. This is because 51
is the specific host in the network address, which is most specific.
arpa is the least specific part of the entry.
- The Domain Name System was released first in the United States and
with that, based on the type of organization that you were, the domain
was supposed to indicate which type of group you were. Some of these,
such as edu, gov, and mil are still used exclusively in the US, while the
others are used across the world.
The three letter top level domains are:
Code | Meaning | Example |
com | Commercial. Now an international top level domain. | ibm.com |
edu | Educational. | harvard.edu |
gov | Government Organization. | whitehouse.gov |
int | International Organization. | nato.int |
mil | Military. | army.mil |
net | Network related, such as an Internet Service Provider | verio.net |
org | Miscellaneous Organization, generally non-profit | redcross.org |
- Two Letter Top-Level Domains
- The two letter codes are used to indicate the country of origin and
are defined in ISO
3166. These are commonly used for municipalities such as cities, police
stations, and other organization in the US, while abroad they are used
as main naming schemes for many domains. In some countries there
are sub-domains indicating the type of organization such as ac.uk, co.uk,
sch.uk in the United Kingdom and edu.au and com.au in Australia.
How does DNS work?
There are two systems involved in DNS. The first system is called a resolver and is built into all computers on the web today. The resolver is responsible for looking up information about a hostname and translating it into an IP address. When you are browsing the web, you are typing in names for machines on the InterNET, such as www.mindflip.com. When you type this into your browser, your computer will query the name servers programmed into it. The name server that is queried will look in its own information to see if it has authoritative or cached information about the domain in question. If it has this informaiton locally, it will then relay this information to your computer and your browser will then go to the site. If the name server does not have the information locally, then it will ask the root name server where authoritative information for that domain can be found. In the case of www.mindflip.com, this information can be found at:Domain servers in listed order:
R2D2.JVNC.NET
128.121.50.2
DNS3.JVNC.NET
192.12.211.11
These machines hold all the information about mindflip.com. The name server will then ask these name server for the IP address for www.mindflip.com. These servers will reply with 206.50.17.92 to the name server, which will in turn, relay this to your computer so you can go to the website.
This may sound complex, but it is equivalent to going to the index in an encyclopedia to find out where information can be found for a given subject. Thus, when you want to find something about Benjamin Franklin, you go to the index to find out which books the information is in. The index can be considered the root name servers. When you go to the main article for Benjamin Franklin, there will be references to other articles about him. Think of the main article as the authoritative name server for Benjamin Franklin.
The second system involved in DNS is the database and records that contain all the information about all the domains in the world. The root name servers have all the information about where a domain can be found, but do not contain any actual information about a given host in a domain. They simply refer you to another server to find that information.
How does DNS really work?
The DNS is system is defined in article RFC 1591. This article lays out the structure of the domain system, including the 7 top level domains listed above, the arpa system for reverse dns, and the two letter country code domains. InterNIC is defined as the controlling authority for the com, edu, gov, net, and org top-level domains. The domains in the mil hierarchy are registered by the DDN registry at NIC.DDN.MIL. Domain names in int are registered by the PVM at ISI.EDU.RFC 1035 defines how DNS systems will internact with each other, the types of packets that are exchanged between machines to transfer DNS information, the character sizes of domains and legal characters in domain names, and the types of records used in the internet. Only the top 7 listed below are in common use today:
Record Type | Description |
A | Maps a name to an IP. |
NS | Maps a name server to a domain. |
PTR | Maps an IP to a name. |
MX | Maps a mail server to a domain |
SOA | Marks the start of authority for a domain. |
CNAME | Points one host name to another host name. |
TXT | Used for comments in the zone file. |
MF | A mail forwarder. Now obsolete in favor of MX. |
MD | Mail destination. Now obsolete in favor of MX. |
MB | A mailbox domain name. (experimental) |
MG | A mail group member. (experimental) |
MR | A mail rename domain name. (experimental) |
NULL | A null RR. (experimental) |
WKS | A "Well Known Service" description. |
HINFO | Host information. |
MINFO | Mailbox or mail list information. |
Also defined are 4 classes of records or which only the first one is
in common use today:
Class | Description |
IN | Internet |
CS | The CSNet class. Obsolete. |
CH | The Chaos class. Also obsolete. |
HS | Hesiod class. Also obsolete. |
Communication between servers
The message formats used for exchange of queries and responses between
hosts and DNS servers is specified in RFC
1035. Queries and responses can be transferred either through TCP or
UDP. There are "well-known" port numbers for
DNS service using either protocol. Port 53 is defined per RFC
1001 as the port for both TCP and UDP DNS transfers.