0

I have two hosted zones (main.mydomain.com and backup.mydomain.com). They include similar records (more than 100 records). Their records only differ in value/route traffic to. The main subdomain records route to my resources in my main AWS region and the backup subdomain records route to my resources in another AWS region that I use as backup. In case of disaster recovery, I'd like to disable or delete the main hosted zone and reroute *.main.mydomain.com to *.backup.mydomain.com. Is it possible? If yes, how can I do it?

In my main hosted zone, I tried adding a CNAME record with an empty record name and the value of backup.mydomain.com and I got the following error.

Bad request.
(InvalidChangeBatch 400: RRSet of type CNAME with DNS name main.mydomain.com. is not permitted at apex in zone main.mydomain.com.)
4
  • My help : stackoverflow.com/questions/20215729/…
    – Asraful
    Feb 1 at 13:45
  • 1
    Have you considered using R53 features such as failover routing? If so curious why you didn't use it, but if it's not suitable can think about your actual question docs.aws.amazon.com/Route53/latest/DeveloperGuide/…
    – Tim
    Feb 1 at 19:20
  • @Tim thanks. It sounds like a better idea than what I was trying. I should use health checks and failover routing instead. Feb 2 at 8:17
  • @Asraful thanks for your comment. I had seen that post. But, I couldn't figure out how to fix it. Maybe my approach was just wrong. Feb 2 at 8:19

1 Answer 1

1

Rather than answering your question directly, I'll make an alternate suggestion: use Route53 routing features such as failover routing. Based on health check Route53 can send requests to whichever region is healthy. If you use two regions each region needs the capacity to service all the traffic. If you use three regions each region has to be able to serve half the traffic.

With health checks and Route53 weighted routing you could send various levels of traffic to each region, such as 99% to your main region, 1% to the backup region to show it's working. When you want to do and update you push all the traffic to the other region.

With Geolocation routing you can have the region closest to the user serve the traffic, which makes things faster for your users.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .