Domain Name System

What is DNS?


IP Addresses are the phone numbers of a network. If you want to talk to another computer on your network... you need their IP address (phone number).

Computers can be assigned canned IP addresses (dynamic) or they can ask for specific IP address (static). When you want to talk to a computer you send packets, such as tcp, over the network to it's address.

Sounds simple... and it is... for a computer... not so much for us. Put in simple terms... Computers do numbers well... We do names well.

Hello... DNS! The Domain Name System (DNS) operates like a phone book. You look up a name and find the telephone number. In DNS you lookup a domain it returns the IP address. Wherever you need to go on the network... you must have and address which means you must resolve a name to that address. DNS servers (nameservers) do just that.

CREATED 2012-12-09 20:08:22.0

00-18-B5

UPDATED 2012-12-09 20:08:38.0

The Domain Name


There is a catch... like phone numbers belong to the phone company, IP addresses belong to an ISP. So you can't own one (unless you are a really big corporation or really rich). That puts web site operators and anyone that deals over the web at a dis-advantage. If you want to change ISPs you will have to change IP addresses.

Introducing... the Domain Name. A Domain Name you can buy (more like rent) and associate it with your IP address. Or in DNS terms... point it at your address.

This way if you move and have to change ISPs you won't have an interuption in service when your IP changes. You only need to change your DNS records to point at your new IP address.

CREATED 2012-12-09 20:18:57.0

00-18-BC

UPDATED 2020-05-01 11:14:42.0

Zones


As computers become more useful... and less expensive... there are increasingly more of them. And of many types. Each requiring IP addresses to talk acrossed networks. With this in mind a domain can become quite a large thing to manage.

Look at any large corporation and you could easily understand that one domain can encompass many different entities. Several departments across several buildings... or cities... even countries. This would be extremely hard to manage from one location.

Introducing the DNS Zone. A zone is a division of a domain. A zone can be an entire domain or it can a small part of a domain or a sub domain.

Nameservers (DNS Servers) load domain information from zone files. When a domain has one or more Nameserves it is said to take authority for it's domain.

Although zone files are cryptic by nature... they aren't really that hard to digest once you understand some basic DNS rules and naming conventions.

CREATED 2012-12-09 20:19:09.0

00-18-BD

UPDATED 2020-05-01 11:51:02.0

The Rules


  • The SOA record ALWAYS starts the zone file. It identifies the zone name the name server, the owner and some statistics about the zone.
  • The @ symbol is short hand for the domain name. Example: @ in a leistware.com zone file means leistware.com
  • Any entry that does not end in a dot (.) will have the zone name appended to the end. (This is important). This record will be myserver.domain.name myserver IN A 1.2.3.4
  • IP Addresses are only allowed on the right side of A records. Never on any other record type and never on the left. database IN A 1.2.3.4
  • in DNS all records are of type IN which stands for INternet. Even if the network isn't on the internet.
  • ; is the start of a comment... everything after that is ignored. ; This comment will be ignored when the zone file is read...
  • if a record does not start with a alpha-numeric name, the name on the last record is repeated. Example: web   IN   A   1.2.3.4       IN   A   1.2.3.5 Both IP addresses 1.2.3.4 and 1.2.3.5 will point to web.domain.name.

CREATED 2020-05-01 13:05:21.0

010-00-00-EC

UPDATED 2020-05-01 13:30:34.0

DNS Records Types


The A record (IPv4) and the AAAA record (IPv6) are the basic records for any zone file unless the zone is completely dependent on other zones which is probably far fetched.

       @   IN   A   1.2.3.4    @   IN   MX   10   1.2.3.4    @   IN   MX   20   1.2.3.5 OtherServer   IN   CNAME   server132
  • A/AAAA - points the domain or sub domain to a resource (IP address)
  • MX - Mail EXchange record points to a mail server. This record has an added attribute, the wieight.


  • These two records identify two mail servers, one as a primary (10) and the other as a backup (20).

  • CNAME - Canonical NAME - a nick name for a server. If you had a server with an official name of server132 but you wanted to refer to it as OtherServer

  • NS - Name Server - These are DNS servers
  • SRV - Service Record - identifies a service and how to contact it. SRV records allow you to identify a port as well as an IP address. THe are however, not widely used.
  • SOA - Start Of Authority - Heads up a zone file

CREATED 2012-12-09 20:19:44.0

00-18-BE

UPDATED 2020-05-01 13:30:33.0

SRV Records...


SRVCE   prot   owner-name   TTL   CLASS   pri   weight   port   target _http._tcp.leistware.com. IN SRV 0 5 80 web1.leistware.com. _ldap._tcp.leistware.com. IN SRV 0 6 389 ldap.leistware.com.

A SRV or Service Record is a DNS record that points not only ot an ip address but also a port. I know... good stuff huh? This gives us the ability to use the same name to address diverent services. For example: leistware.com can address the web server and primary domain controller.

The record is formatted like this:

Explanation:

Name Description
srvce The service to be addressed or identified. Always begins with an underscore. Example _http or _ssh. Follows the ianna port numbers.
prot Protocol - the protocol to be referenced. Alwasy begins with an underscore. Example _tcp or _udp See ianna service names.
owner-name The domain like example.com
TTL Optional. The standard Time To Live
Class The resource record class i.e. IN for INternet
PRI PRIority - this is like MX records a number from 0 - 65535
Weight Further defines priority. The weight is used when two records have the same priority
port The port the service is running on.
Target The Host the service is running on.

Real example: Using SRV records we can establish a pointer to two different servers using the same domain name.


These two records distinguish between the web server for leistware.com and the ldap server for leistware.com.

CREATED 2020-02-21 09:30:45.0

010-00-00-75

UPDATED 2020-05-01 13:05:27.0

NOTE


If Windoze does not reload DNS information for recent changes to the zone files... REBOOT!

CREATED 2017-04-26 14:25:32.0

00-29-B4

UPDATED 2020-05-01 13:05:29.0

DBID: db.wam

Page Server: Ithica

©2012 Leistware Data Systems

      Hello anonymous