Failover records are very similar to regular DNS records, in that they point a domain to an IP address or hostname but you can also specify a backup IP or hostname. The backup is only used if the primary is unavailable.
Failover uses health checks to monitor the availability of the endpoints in your failover records. If an endpoint is suddenly unhealthy, our monitoring nodes will run a quick health check for the backup endpoint. If it is available, the record will update and point to the backup endpoint.
Failover can be combined with GeoDNS services like GTD and IP Filters to create “regional failover” configs. You can learn about those here. Since failover uses health monitoring, you will need access to the Sonar monitoring application. First, you need to create monitoring checks for all the endpoints in your failover record (primary and backups). Then apply those health checks to appropriate endpoints in your failover record.
Clone the check you just made by clicking the button in the upper right-hand corner of the check configuration screen. Change the name and IP/FQDN values to match your secondary endpoint. Test the check and save. Rinse and repeat for however many endpoints you want to include in the failover configuration.
#3 Switch to the DNS App
In the bottom left corner, click the Switch Apps button and select the DNS application.
#4 Create Record
Create the appropriate record. For this example, we want to create an A record since we are pointing to an IP address. Enable Failover in the Record Mode menu.
There are three failover settings you can choose from. Let’s say you have three endpoints called A, B, and C. This is how each setting would failover traffic to each with A being the primary and C being the tertiary.
Normal A to B. If A is back up, then A. If both A and B are down, then C.
Off on Any Failover Event A to B, then stops. Stays at B until failover is turned back on.
One Way A to B to C, then stops.
Failover with Round Robin You also have the option to combine failover with round robin, which is our load balancing service. That means each time the record is queried, a different endpoint would be returned. If we have three endpoints in the record, each endpoint has a 33% chance of being returned. If any of these endpoints are down, then they will be removed from the configuration.
Query 1: A Query 2: B Query 3: C Query 4: A is down so B is returned Query 5: C Query 6: B …and so on
Add Endpoints Make sure you add your endpoints in order of priority, ie: the first row should be your primary endpoint. Click Add Another IP to add another endpoint.
Integrate Monitoring In the Sonar Check column, click the dropdown menu. Any monitoring checks that match the IP/FQDN in that row will appear in the dropdown. Choose the one you want to use with this check and in the Status column you will see the current status of the check.
When you are done adding the necessary endpoints and checks, Save your check and Commit your changes.
Your failover record will propagate instantly to all of our nameservers, so you can immediately query them in a terminal to make sure your record is live. In the Records screen, you can see which IP/FQDN is being returned in the IP/Pool column with an asterisk.