/ informatics / network /
Domain Name System (DNS) 
The Domain Name System (DNS) is a hierarchical decentralized naming system for computers connected to the Internet 1. It allows to access servers by name instead of an IP address which is hard to remember.
Resource Record Format
All RRs have the same top level format shown below:
<NAME> <TTL> <CLASS> <TYPE> <RDLENGTH> <RDATA>
- NAME: the name of the node
- TTL: a 32 bit signed integer that specifies the time interval that the resource record may be cached
- CLASS: two octets containing one of the RR CLASS codes.
- TYPE: two octets containing one of the RR TYPE codes.
- RDLENGTH: an unsigned 16 bit integer that specifies the length in octets of the RDATA field.
- RDATA: a variable length string of octets that describes the resource.
Resource Record Types
|DNS Type||Return Type||Application|
||IPv4 address||map domain to 1 static IP|
||IPv6 address||map domain to 1 static IP|
||Domain name||map domain to domain|
||Canonical name||map 1 domain to 1 domain|
||Delegation name||map domain + subdomains to domain|
||Name server||delegate to other DNS|
||Public key||provide authentication|
||URL||Mail exchange server|
||URL||redirect (HTTP 301) domain to URL|
The DNAME record provides redirection for a subtree of the domain name tree in the DNS 2. Note that a
DNAME entry that maps
public.com will also map
ALIAS type is not part of the DNS standard and should only be used to map an Apex domain to another domain because
CNAME cannot be used for this task.
Rules for setting up a DNS entry
- use an
AAAArecord if your destination is a server with one static and fixed IP address (this is the most common case)
- use a
CNAMErecord if you want to alias a name to another name, and you don’t need other records (such as
MXrecords for emails) for the same name
- use an
ALIASrecord if you are trying to alias the root domain or if you need other records for the same name
Changes propagate within the network in about 24 hours. TTL of records: 5 minutes to 24 hours.
RFC 1035, Domain Names - Implementation and Specification , 1987↩
RFC 6672, DNAME Redirection in the DNS, 2012↩