Weighting Fault-Tolerant Multi-Record Answers in Amazon Route 53
An Amazon Route 53 weighted resource record set can only be associated with one record, meaning a combination of
one name (for example,
example.com) and one record type (for example, A). But it is often desirable to
weight DNS responses that contain multiple records.
For example, you might have eight Amazon EC2 instances or Elastic IP endpoints for a service. If the clients of that service support connection retries (as all common browsers do), then providing multiple IP addresses in DNS responses provides those clients with alternative endpoints in the event of the failure of any particular endpoint. You can even protect against the failure of an availability zone if you configure responses to contain a mix of IPs hosted in two or more availability zones.
Multi-record answers are also useful when a large number of clients (for example, mobile web applications) share a small set of DNS caches. In this case, multi-record answers allow clients to direct requests to several endpoints even if they receive a common DNS response from the shared cache.
These types of weighted multi-record answers can be achieved by using a combination of resource record sets and weighted alias resource record sets. You can group eight endpoints into two distinct record sets containing four IP addresses each:
endpoint-a.example.com, type A, with the following values:
endpoint-b.example.com, type A, with the following values:
You can then create a weighted alias resource record set that points to each group:
endpoint-a.example.com, type A, weight 1
endpoint-b.example.com, type A, weight 1
For more information about creating resource record sets, see Working with Resource Record Sets.