Domain Name System (DNS)
DNS is a process of mapping a human-friendly domain name to an IP address.
- DNS Root Servers: A group of servers to answer the root zone. Top Level Domains (TLDs) are controlled by the root zone database – Internet Assigned Numbers Authority (IANA).
- Domain Registrars: All domain names must be unique. A registrar is an authority that can assign domain names to top-level domains and ensure its uniqueness. Each domain name becomes registered in a central database (WhoIS server).
- Top-Level Domain (TLD): the top tier in the DNS hierarchy, the last part of the domain (.com, .ca …)
- Subdomain: Anything between a host and TLD
- Zone, Zone file: a mapping of IPs and hosts for a given subdomain
- Host: A record in a zone file: www, mail, …
- Name Service: a server that runs a DNS service
- FQDN: Fully Qualified Domain Name: host + subdomain + top-level domain
Registering a domain within DNS
- Check the domain is available.
- Purchase the domain via a registrar.
- Host the domain.
- Create records in the zone file: (www., mail., http://ftp., …)
- Hosted Zone is a container for DNS records relating to a particular domain.
- Public Zones: visible from Internet and VPCs
- Private Zones: visible only from the VPCs that are associated with
- VPC Settings: EnableDnsHostnames and EnableDnsSupport
- Split-View DNS is supported.
- Use the same zone name for public and private zones.
- Provide VPC resources with different records – testing or internal application
- NS and SOA records are created in a zone by default.
- A or AAAA (Address): for a given host, provides an IP4 or IP6 address – fundamental type.
- CNAME (Canonical Name): resolve one domain name to another; allows aliases to be created.
- Alias: an extension of CNAME, map one DNS name (www.test.com) to another DNS name of AWS resources such as load balancers or CloudFront distributions (elb12.elb.amazonaws.com)
- MX: the mail servers for a given domain
- NS (Name Server): set the authoritative servers for a subdomain used by TLD servers (.com would have NS servers for test.com)
- TXT: descriptive text in a domain – often used to verify domain ownership
- PTR: reverse of A record, resolve a name from an IP address
- SOA (Start of Authority): A type of resource record in the DNS containing administrative information about the zone. Every domain data starts with SOA
- The name of the server, the administrator of the zone, the current version of the data file, the default TTL (Time to Live) on the resource records
[Note] ELB (Elastic Load Balancer) does not have a pre-defined IPv4 address. A DNS name is used to resolve the address.