Certopolis

AWS Certified CloudOps Engineer – Associate

Route 53 routing policies and health checks for SOA-C03

The Amazon Route 53 Developer Guide lists the routing policies: failover for active-passive, weighted for traffic in set proportions, latency for the Region with the lowest latency, and geoproximity for the closest resource with an adjustable bias. Health checks decide which records are eligible, and a record with no health check is always treated as healthy.

Which routing policy fits which need?

Failover routing sends traffic to one resource while it is healthy and to another when it is not. Weighted routing splits traffic across records with the same name and type in proportion to each weight as a share of the total; weights of 1 and 255 send 1/256th to the first.

Latency routing answers with the record for the AWS Region that gives the user the lowest latency. The data comes from traffic between users and AWS data centers and changes over time.

Geoproximity routing sends traffic to the closest resource. A positive bias from 1 to 99 expands the area that routes to a resource and shrinks the adjacent ones; a negative bias from -1 to -99 shrinks it. AWS suggests changing bias in small steps.

Simple routing is for a single resource, geolocation routes by the location of the user, and multivalue answer returns up to eight healthy records chosen at random.

How do health checks change the answer?

Route 53 first picks a record by the routing policy, then checks whether it is healthy. If it is not, it picks again until it finds a healthy record. Health is checked periodically, not when the query arrives.

A record without an associated health check is always considered healthy. A failover primary with no health check therefore keeps being returned even when the resource is down.

If no record in the group is healthy, Route 53 treats all of them as healthy and chooses by the routing policy.

Weight 0 stops traffic to a record in normal operation. But when every record has a health check and all the records with nonzero weight are unhealthy, Route 53 considers the zero-weight records. Make sure a zero-weight target can give a usable answer.

When do you need an alias record?

A CNAME record cannot exist at the zone apex, such as example.com. An alias record can, and it can point at AWS resources such as an Elastic Load Balancing load balancer, a CloudFront distribution or an S3 website bucket.

Route 53 answers an alias query with the resource's current IP addresses and follows them when they change. You cannot set the TTL of an alias record that points to an AWS resource. For health, set Evaluate Target Health to Yes so Route 53 checks the resource the alias points to.

Where the exam catches people

  • Setting up failover records without a health check on the primary: a record with no health check is always considered healthy.
  • Believing weight 0 means never returned: zero-weight records are considered when all nonzero-weight records are unhealthy.
  • Creating a CNAME for the zone apex: use an alias record there.
  • Choosing geolocation to move a boundary between Regions: geoproximity bias is the setting that expands or shrinks a resource's area.
  • Believing all-unhealthy means no answer: when no record is healthy, Route 53 treats all records as healthy.

Written from these sources

Try 3 questions on this

Pick an answer to see why each option is right or wrong.

  1. Route 53 failover records answer app.example.com. The primary record points to the Elastic IP address of an Amazon EC2 instance in us-east-1, and the secondary record points to the Elastic IP address of a standby instance in us-west-2. When the primary instance stopped last night, Route 53 kept answering with the primary's address for two hours. What should the SysOps administrator do so that Route 53 answers with the secondary when the primary fails?

    Right. In the game that’s Renown for your Networking and Content Delivery building.

    Not that one: A is right. In the game your Networking and Content Delivery building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    A health check on the primary instance's Elastic IP address, associated with the primary record, lets Route 53 switch to the secondary when the instance stops answering.

    Written from docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy-failover.html

  2. Route 53 weighted records for www.example.com point to three web servers. Two records have weight 50; the third, for a server that shows a maintenance page, has weight 0. All three records have health checks. Last night both weight-50 servers failed their health checks, and users were sent to the maintenance server, which the team expected never to receive traffic. What is a reason for this issue?

    Right. In the game that’s Renown for your Networking and Content Delivery building.

    Not that one: B is right. In the game your Networking and Content Delivery building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    Once all of those are unhealthy, it considers the zero-weight records, and the maintenance server's record was healthy, so it was returned. While either weight-50 server is healthy, the maintenance record gets nothing.

    Written from docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy-weighted.html

  3. A company runs a game leaderboard API behind Application Load Balancers in eu-west-1 and ap-northeast-1. Players in Europe, Asia and elsewhere report slow responses. A SysOps administrator must configure Route 53 so that each player's lookups return the load balancer in whichever of the two Regions responds fastest for that player. Which solution will meet this requirement?

    Right. In the game that’s Renown for your Networking and Content Delivery building.

    Not that one: D is right. In the game your Networking and Content Delivery building would lose a little Renown, and this question would come back later.

Ask for something