- Newest
- Most votes
- Most comments
To achieve faster failover (10-20 seconds) in your active-passive configuration with Route 53, you need to optimize several aspects of your current setup:
- Health Check Configuration:
- Your current health check interval is 10 seconds with 2 retries, which means it could take up to 30 seconds (10 seconds × 3 checks) to detect a failure
- Consider reducing the health check interval to the minimum allowed (typically 10 seconds)
- Reduce the failure threshold to 1 retry instead of 2 to detect failures faster
- DNS TTL Settings:
- While you've set the TTL to 10 seconds, which is good, be aware that some DNS resolvers might ignore very low TTL values and cache responses longer
- Ensure your application is configured to respect DNS TTL values and not cache DNS resolutions internally
- Failover Configuration:
- Ensure you're using proper failover routing policy in Route 53, with one record designated as "Primary" and the other as "Secondary"
- The primary record should have the health check associated with it
- For the secondary record, you can either associate a health check or set "Evaluate Target Health" to "Yes" if it's an alias record
- Client-side Considerations:
- DNS caching on client machines or intermediate DNS servers might be extending your failover time
- Some clients or applications might cache DNS resolutions longer than the specified TTL
In active-passive failover configurations, Route 53 automatically changes to the secondary resource when the primary becomes unhealthy, and automatically fails back when the primary becomes healthy again. If you need to control the failback process manually, you can either deactivate the health check or use weighted routing instead of failover routing.
Remember that even with the most optimized configuration, there will always be some delay in failover due to the nature of DNS propagation and caching.
Sources
Active-active and active-passive failover - Amazon Route 53
Prevent the automatic failback with a Route 53 health check | AWS re:Post
Disaster recovery options in the cloud - Disaster Recovery of Workloads on AWS: Recovery in the Cloud
Relevant content
- AWS OFFICIALUpdated 2 years ago

Thanks Gary for the detailed Answer. For my above use case, are there any other options on AWS than the Active - Passive fail over using A records?