AWS Route 53 Notes

Posted: 05 June, 2020 Category: rough notes Tagged: route53awsDNS

DNS Records - a wee and oversimplified glossary

Record type Full Name Simplified Description
A Record Address Record Assigns an IP address for a domain (i.e. a name => n.n.n.n mapping).
CNAME Record Canonical Name Record allows several aliases to be mapped to the same domain. eg =>
NS Record Name Server Reord Used by TLD servers to direct traffic to the content DNS server which contains the authoritative DNS records
SOA Start of Authority Record data identifying the adminstrator of a zone, default time-to-live, version, etc.
TLD Top Level Domain e.g. ".com", ".org", etc.
TTL Time To Live indicates when the related information should be deemed "expired", causing fetch of more upt-to-date data. Default TTL can be 24hrs or even 48 hrs.

DNS at a glance

Birdseye view of DNS

Routing Precedence in terms of AWS components

Obviously this is oversimplified but it's a good visual mnemonic as to where you are in the chain of things. Routing components

AWS Route 53 Routing Policies

Routing policies determine how traffic is routed to a bunch of available servers.

  • Simple Routing: yield any server
  • Weighted Routing: { x% of traffic => server 1, y% of traffic to server 2, ... etc}
  • Failover Routing: yield the assigned secondary server if the primary is failing
  • Geolocation Routing: yield endpoint in user's region (regardless of latency)
  • Geoproximity Routing: The most complex routing policy. Requires creation of a traffic policy first (go to R53 > Traffic flow > Traffic policies). yields endpoint based on user's location AND the location of your resources AND any biases you've set up in your traffic policies... whew!
  • Multivalue Answer:

Remember that with all of these, end-user side (browser-side), you will generally keep hitting the same yielded ip/endpoint until the configured TTL expires.

Route53 Routing Policies

You implement routing policies with Route 53 DNS "Record sets". For the most part (from what I gather) you will be implementing your routing polices as A records.

As an aside: since amazon is a domain registrar you can actually buy your domain right in AWS (currently common TLDs go for around $12USD)- or just bring your own. I guess if you buy from them, the NS records wil be setup for you, otherwise you would be going to your domain registrar and adding AWS nameservers.

Anatomy of a record set:

  • Record Type := (usually an A record)
  • TTL := choose a value that works for you
  • value := the ip address of one of your EC2 instances, for exmaple
  • routing policy := as described earlier. pick one.
  • set id := this is just a descriptor for yourself
  • associate with healthcheck := check this if you want R53 to omit endpoints that are failing healthchecks, from being yielded in routing policy algos.