If server A is down redirect to Server B

Can this possibly be done? If yes how to approach it?

I have a website called xyz.com hosted at “server A” located in a data center at Miami. Xyz.com is being monitored for uptime with a script in a one-minute interval. If xyz.com goes down for more than 5 minutes, “server B” located at San Francisco will host xyz.com instantly until “server A” is up again traffic will go back to “server A”. Can this be done?

Thank you and happy new year
jb

The redirection would have to come from within Server A as all the DNS pointers around the world are sending your requests there. If that server goes down, there would have to be a software switch in that data center to make the redirection - but I’ve never heard of anything like that (although I’m just as sure MAJOR website have multiple server to accomplish this automatically).

Regards,

DK

A search for FAILOVER might provide clues as to how it is done.

I just have an idea. Since we have server monitor service and if “server A” goes down, we can manually change the DNS of xyz.com to “server B”, but my concern is the DNS propagation. This unpredictable sometime is fast other time can take days.

Right! Ergo, a forward at the failed server is best (but has to be implemented by the data center).

Regards,

DK

DNS propagation isn’t unpredictable. Each DNS server updates at set intervals. Some update many times each day, some update every day or two, some only update every few weeks. How quickly domains appear to propagate depends on which DNS you check. By the time your DNS change had propagated you could have completely rebuilt the original server regardless of what the problem causing it to go down was. For your failover to work both servers must be set up to use the same IP address with the failover software determining which of the two has the internet connection so as to be able to be referenced at that address.

I just got a reply from Godaddy where my site was registered with. They said .com and .net usually update their DNS table every 4-6 hours. Any providers out their would update faster?

Just because GoDaddy update those domains in their DNS that quickly doesn’t mean all the others do. A few are possibly faster than that but there are probably as many that only update weekly as update more frequently than four hours and since you can’t control which DNS server your visitors use there will be at least some visitors who will not see the new server after a DNS change for at least a week or more.

You need to use a DNS solution that supports “FAILOVER”. Basically what happens is when it detects SERVER A is down, it points all traffic to server B.

There are many 3rd party solutions that do this. We have a few customers that have this setup and I’ll be glad to point you in the right direction if you need assistance.

I basically pointed that out right at the start of this thread but the original poster appears to be ignoring that and trying to figure out how to do it without using any of the methods that are set up specifically to handle that situation. Whatever they come up with will not work as well as a FAILOVER solution designed specifically for that situation would but I guess if someone wants a less than perfect solution instead of a perfect one then that’s their choice.