Before migrating domains to Amazon’s Route53, we should first make sure we properly understand how DNS works

While we’ll get to AWS’s Route53 Domain Name System (DNS) service in the second part of this series, I thought it would be helpful to first make sure that we properly understand just how DNS works in general. Once we’re comfortable with the DNS process and terminology, we’ll explore migrating existing domains to Route 53.

The Domain Name System provides mapping between human readable  names (like www.amazon.com) and their associated IP addresses (like 205.251.242.103). How DNS works can be best compared to a phone book where you look up the phone numbers listed by easier-to-remember names. DNS  comes under the application layer protocol.

How DNS works graph

A user types “www.amazon.com” in his browser, which then queries the Domain Name System server for amazon.com’s IP addresses. DNS servers return Amazon’s address so the browser can request data from Amazon’s web host, which returns the elements necessary to build their home page in the local browser.

How DNS works: Domain Name System Terminology

Domain Names

A domain name is human readable name – like amazon.com – that we type in a web browser URL field. The Internet Corporation for Assigned Names and Numbers (ICANN) manages  these domain names

Top Level Domain (TLD)

TLD refers to the last part of a domain name. For example, the .com in amazon.com is the Top level domain. The most common TLDs include .com, .net, org, and .info. Country code TLDs represent specific geographic locations. For example: .in represents India. Here are some more examples:

  • com – Commercial businesses.
  • gov – U.S. government agencies.
  • edu – Educational institutions such as universities.
  • org – Organizations (mostly non-profit).
  • mil – Military.
  • net – Network organisations.
  • eu – European Union.

Second level Domain

This is the part of a domain name which comes right before the TLD, “amazon.com”, for example.

Sub Domain

A sub domain can be created to identify unique content areas of a web site. For example, the aws of “aws.amazon.com”.

How DNS worksDomain Name Registrar

By managing domain name reservations, name registrars are critical to how DNS works. ICANN currently grants permission to organizations to act as domain name registrars for specific higher level domains.

Name Server

Like a phone book, the name server is a collection of domain names matched to IP addresses.

How DNS works: Domain Name System record types

A Record

Address records (“A Records”) map server IP addresses to domain names. For example, 72.21.206.6 to amazon.com.

CNAME

Canonical Name record. A CNAME record establishes one domain as an alias to another (thereby routing all traffic addressed to the alias to the target; the canonical address)

Alias Record

Like a CNAME record, Alias records can be used to map one address to another. But Aliases can coexist with other records using the same name.

MX Record

Mail Exchange Record. These records will redirect a domain’s email to the servers hosting the domain’s user accounts. Mail exchange records are used for determining the priority of email servers for a domain.

How DNS works

When a user types a human-readable address in his browser, the operating system’s DNS client will check for information in a local cache. If the requested address isn’t there, it will look for a Domain Name System server in local area network (LAN). When the local DNS server receives the query and the requested domain name is found, it will return the result.

If the name is not found, the local server will forward the query to a DNS cache server, often provided by the Internet service provider (ISP). Since the DNS server’s cache contains a temporary store of DNS records, it will be able to quickly respond to requests. These DNS cache servers are called “not authoritative DNS servers” as they provide request resolution based in a cached value acquired from “authoritative DNS servers.”

An Authoritative Root name server maintains and provides a list of authoritative name servers for each of the top-level domains (.com, .org etc).

An Authoritative Top level domain name server maintains and provides a list of authoritative name servers for all domains (gmail.com, wikipedia.org etc). It’s job is to query name servers to find and return the authoritative name server for the requested domain.

Now that we’ve got a better idea how DNS works, the next post will introduce you Amazon’s Route 53 and show you how easy it can be to migrate your existing domains to it.

  • Atul Shah

    Hi Nitheesh,
    today I got some tweet from thah some how came across you blog. your blog s are amazing . Please keep it up…
    thanks for all your up coming blogs

    • Nitheesh Poojary

      Thanks Atul for the feedback. Will Definitely write good blog post in coming days

  • Atul Shah

    hey, Nitheesh,, One doubt.
    what is the difference between sub domain name and CNAME record?
    Eg: “aws.amazon.com” here aws is sub domain.
    ” doc.university.com ” here doc is CNAME.
    would you mind explaining this please?

    also It would be great help if could give example for “Alias”