Quote:
Originally Posted by muliahosting
Hello Spiral,
I already setup "failover" like your suggestion, create www and www1 with different IP/location. But what I want to do is:
If www (as main webserver) down then I execute some scripts on main DNS server to change IP of www to IP of www1 and spread to slave DNS.
Thank you.
|
A round robin effect as described by Spiral would be much more effective. Due to such factors as DNS propogation etc even if the DNS switched straight away the would be hours of downtime for DNS propogration to the new IP then if you switch it back you would have to wait for it to propogate again. The easiest way is to do what Spiral said which would just cause all requests to go to the live server but it would cause the requests to go to both servers not just the main one and the second one. If you wanted to specificaly use one main server and one standby then your looking at costly load balancing/network stuff Id guess.
Also why www and www1 :S
I mean if you really wanted to do it you would have to edit the raw DNS file then reload BIND but I dont think there is an API call to push the config accross a cluster. So in effect till there is an API function to do it it would be quite tricky.