Weighted Routing – Domain Name Services – ANS-C01 Study Guide

Weighted Routing

Weighted routing is based on the round-robin policy but adds a weighted feature to affect how the load gets distributed. Multiple hosts with different IP addresses all serve the same content. Each host will then have a weight assigned to it between 0 and 255. If they are all set to the value of 0, then traffic is distributed evenly across all the servers just like round-robin does. However, by changing the weights, each record is assigned a value that is the weight, and the load is dispersed as a percentage of the total value to the total weight assigned, as shown in Figure 2.17.

FIGURE 2.17 Route 53 weighted routing policy

Geolocation

Geolocation policies will examine the user’s source IP address, determine where it is physically located, and serve traffic based on their location. Then a lookup is done, and the reply will direct them to the defined location. Restrictions can be placed at the country, state (in the United States), or continent level. Geolocation can direct users to local websites that host content in their local language or where regulations restrict traffic to originate from. Geolocation maps IP addresses to locations by using the mapping and learning the location routing decisions based on the policy configured, as shown in Figure 2.18.

FIGURE 2.18 Route 53 geolocation routing policy

You can configure geolocation by continent and then be more granular by country. The country level will take precedence over the more broadly defined continent. Also, if a continent is defined, geolocation will favor the smaller region. For example, if there is a geolocation policy for Europe and you have web servers in AWS regions located in Ireland and Germany, Ireland would take precedence since it is the smaller geographic region. This policy can then be modified to add country codes to send traffic from the defined country to the AWS Frankfurt region.

In the case that geolocation cannot determine the location of the source IP address, two actions can be taken. The first is to drop the request by not answering the query and not allow it to connect since there is no record provided of where to route the traffic. The second option is to create a default record that routes the unknown originating traffic to the region you specify.

Geo-proximity

Geo-proximity routes traffic based on location just as geolocation, with enhancements to allow you to adjust how the traffic gets routed based on a value called bias, as shown in Figure 2.19. The bias increases or decreases the geographical size of the region that traffic gets routed to. Geo-proximity works for both AWS and non-AWS resources. If the resource resides in an AWS region, then the region is defined in the policy. If the resource is in a non-AWS location such as a corporate data center, then latitude and longitude values are used. Once the resources are defined in the policy, the size of the region can be expanded by adding a positive number between 1 and 99, and it can be shrunk with a negative value between −1 to −99.

FIGURE 2.19 Route 53 geo-proximity routing policy