Table of Contents
hide
AWS Route 53 Routing Policies Comparison
- Amazon Route 53 supports 7 routing policies that determine how DNS queries are answered.
- Choosing the right routing policy depends on whether you need failover, latency optimization, geographic restrictions, or traffic distribution.
- Multiple policies can be combined using alias records and health checks for complex routing architectures.
Route 53 Routing Policies Comparison
| Policy | Use Case | How It Works | Health Checks |
|---|---|---|---|
| Simple | Single resource, no special routing | Returns all values in random order | No (can’t attach) |
| Weighted | Traffic distribution, blue/green, A/B testing | Routes based on assigned weights (0-255) | Yes |
| Latency-based | Best performance for global users | Routes to region with lowest latency | Yes |
| Failover | Active-passive disaster recovery | Primary until unhealthy, then secondary | Yes (required for primary) |
| Geolocation | Content localization, compliance, restrictions | Routes based on user’s geographic location | Yes |
| Geoproximity | Route based on resource location + bias | Routes to nearest resource; bias expands/shrinks coverage | Yes |
| Multivalue Answer | Simple load balancing with health checks | Returns up to 8 healthy records randomly | Yes |
| IP-based | Route by client IP/CIDR (ISP optimization) | Routes based on client subnet CIDR mapping | Yes |
Simple Routing
- Routes traffic to a single resource (or multiple values returned in random order).
- Cannot attach health checks to simple routing records.
- If multiple values are returned, client chooses one randomly (client-side load balancing).
- Can only have one record per name with simple routing.
- Best for: Single server, single resource behind a load balancer.
Weighted Routing
- Routes traffic based on weights assigned to records (0-255).
- Traffic proportion = record weight / sum of all weights for the same name.
- Setting weight to 0 stops traffic to that resource (useful for maintenance).
- If all records have weight 0, traffic is distributed equally.
- Supports health checks – unhealthy records removed from responses.
- Best for: Blue/green deployments (90/10 split), A/B testing, gradual migrations, load distribution across regions.
Latency-based Routing
- Routes traffic to the region with the lowest network latency for the user.
- Latency is measured between the user’s DNS resolver and AWS regions.
- Requires resources in multiple AWS regions.
- Supports health checks – if lowest-latency resource is unhealthy, routes to next-best.
- Latency data is updated periodically by AWS (not real-time per request).
- Best for: Global applications deployed in multiple regions needing best user experience.
Failover Routing
- Routes traffic to primary resource when healthy, secondary when primary fails health check.
- Active-passive configuration – only one designation per record set (primary or secondary).
- Health check required on primary record; optional on secondary.
- Secondary can point to a static S3 website (maintenance page) or another resource.
- Can be combined with other routing policies using alias records.
- Best for: Disaster recovery, maintenance pages, active-passive HA architectures.
Geolocation Routing
- Routes traffic based on geographic location of the user (continent, country, or US state).
- Most specific match wins – state > country > continent > default.
- A default record is recommended – users from unmapped locations get this response.
- If no default and no match, Route 53 returns “no answer”.
- Does NOT route to closest resource – routes to the location you configure (use geoproximity for nearest).
- Best for: Content localization (language), compliance (restrict access by country), serving region-specific content.
Geoproximity Routing
- Routes traffic based on geographic distance between user and resources.
- Bias values (-99 to +99) expand or shrink the geographic area that routes to a resource.
- Positive bias = attracts more traffic (expands coverage area).
- Negative bias = repels traffic (shrinks coverage area).
- Supports both AWS resources (auto-detects region) and non-AWS resources (specify latitude/longitude).
- Requires Route 53 Traffic Flow to use geoproximity routing.
- Best for: Routing to nearest resource with ability to shift traffic between regions using bias.
Multivalue Answer Routing
- Returns up to 8 healthy records in response to each DNS query.
- Similar to simple routing but supports health checks – only healthy resources returned.
- Not a substitute for a load balancer but provides basic DNS-level load balancing with health checking.
- Each record can have its own health check.
- Best for: Basic load distribution with health checking when you don’t need ELB.
IP-based Routing
- Routes traffic based on client’s source IP address mapped to CIDR blocks.
- Create CIDR collections with locations, then map records to locations.
- Useful when you know the IP ranges of your users (corporate networks, ISPs).
- More precise than geolocation – routes based on actual network, not estimated location.
- Best for: ISP-specific routing, enterprise users with known IP ranges, optimizing costs by routing to specific endpoints.
Combining Routing Policies
- Alias records can point to other Route 53 record sets, enabling policy combinations.
- Example: Latency → Weighted (route to nearest region, then split between blue/green within region).
- Example: Failover → Latency (primary is latency-based across regions, secondary is S3 static page).
- Example: Geolocation → Failover (per-country routing with DR fallback).
- Traffic Flow – visual editor for building complex routing trees with multiple policies.
AWS Certification Exam Practice Questions
- A company wants to gradually migrate traffic from an on-premises data center to AWS by sending 10% of traffic to AWS initially, increasing over time. Which routing policy supports this?
- Latency-based
- Weighted
- Failover
- Geolocation
- An application deployed in us-east-1 and eu-west-1 should route users to whichever region provides the fastest response. Which routing policy is appropriate?
- Geolocation
- Geoproximity
- Latency-based
- Weighted (50/50)
- A streaming service must serve different content libraries to users in different countries due to licensing restrictions. Which routing policy enforces this?
- Latency-based
- Geolocation
- Geoproximity
- IP-based
- A company needs to route traffic to the nearest data center but temporarily shift more traffic to a new region during a migration. Which routing policy allows adjusting the geographic coverage area?
- Geolocation with failover
- Weighted with latency
- Geoproximity with bias
- Multivalue answer
- An architect needs DNS-level health checking where unhealthy endpoints are automatically removed from DNS responses, but a full load balancer is not required. Which policy provides this with multiple IPs?
- Simple routing
- Weighted routing
- Failover routing
- Multivalue answer routing
Related Posts
- AWS Route 53
- AWS Route 53 Alias vs CNAME
- AWS CloudFront vs Global Accelerator
- AWS High Availability & Fault Tolerance Architecture