Solved

IP Failover For Internally Hosted Website

Posted on 2012-12-28
7
403 Views
Last Modified: 2014-10-07
One of my clients hosts his own web server with a primary and a failover internet connection:

Lets say our primary IP is 1.1.1.1 and our backup is 2.2.2.2. GoDaddy hosts our name servers so anytime someone wants to go to www.ourdomain.com a DNS host also known as an A record is setup pointing to 1.1.1.1. This works well enough and people land on our website. However if our internet goes down the IP currently changes to 2.2.2.2 which will break the A record setup on GoDaddy and www.ourdomain.com will not resolve. The quick fix is to modify the A record on Godaddy to the failover IP. This will get the site back up and running in just a few minutes. This is the short term solution.

 Given that DNS does not support IP failover here is the solution I propose. Assign the site the IP 3.3.3.3. This site is a service that monitors 1.1.1.1 and 2.2.2.2. By default it will forward all traffic to 1.1.1.1 however if the site goes down it will automatically failover to 2.2.2.2.

What solutions do you suggest for this type of issue? Currently they are happy hosting on site they just need a way for the IP to failover
0
Comment
Question by:Shurafa
  • 2
  • 2
7 Comments
 
LVL 77

Accepted Solution

by:
arnold earned 200 total points
ID: 38728795
Are the two Internet connections always up?

You could use dynamic DNS updates to maintain the record for www pointing to both IPS, load balancing the traffic, when one connection goes away so s the matching record.

If you use the ISP connection in active/failover mode I.e. the routing table is weighted.
Your monitoring process could use dynamic updates to register the host based on the IP from which the request is being made.
The failover period will depend on your TTL setting on the record.
I.e. 30 seconds will mean that the transition of visitors between the two IPs will be 30 seconds between access attempts.

You could delegate the www.ourdomain.com from godaddy to your cloud based DNS if available that will be updated based on the site.
I.e. www.ourdomain.com. IN NS IP1.ourdomain.com.

www.ourdomain.com. IN NS IP2.ourdomain.com.

Each one will fall or stand with the provider. I.e. 1.1.1.1 goes down, all DNS lookups will go to 2.2.2.2 which will reference itself.
When both are on, the request will be distributed between the two IPs.
0
 
LVL 42

Assisted Solution

by:kevinhsieh
kevinhsieh earned 200 total points
ID: 38728820
I have the same type of network setup, where my server is either available via 1.1.1.1 or 2.2.2.2, but never both addresses at the same
time.I use DNS Made Easy and their DNS Failover and Service Monitoring. They monitor my servers and change the A records
automatically as necessary. They return to the original IP when service is restored. I have had the service for several years and it works great. You should probably just move the entire DNS zone off GoDaddy to DNS Made Easy to get this to go. It would be a lot simpler than trying to delegate specific records, and I don't know how you would even do that for domain.com

http://www.dnsmadeeasy.com/dns-services/
0
 
LVL 27

Assisted Solution

by:Steve
Steve earned 100 total points
ID: 38733709
Three options worth considering:

Round Robin DNS:
Create two A records for WWW. DNS servers will usually return these randomly meaning that web traffic will use both lines in normal usage. If one line is down, some users will continue to work reducing the downtime in simple ways

DNS failover records:
Many DNS/nameserver providers CAN provide failover DNS records which update automatically. They arent cheap though.

Dynamic DNS service:
Using a dynamic DNS service allows DNS records to be updated automatically by running a program on your server that reports its current IP to the DNS provider.
0
 
LVL 42

Assisted Solution

by:kevinhsieh
kevinhsieh earned 200 total points
ID: 38733762
IMHO round robin DNS will not work because clients usually only try the first address returned. If they get the wrong address, and 50% of the clients will get the wrong address, they won't even check for a new address until the TTL expires, and even then they have a 50% change of getting the wrong address, and at least some browsers like IE cache DNS responses and require a restart.

DNS Made Easy seems pretty affordable. The failover DNS service costs $4.95 per host per year. Out the door you gave a solution for $35pr year, which is a lot cheaper than your second circuit.

DDNS could work if you can update your address like every 5 minutes.
0
 
LVL 77

Assisted Solution

by:arnold
arnold earned 200 total points
ID: 38733782
Failover DNS would/should include dynamic updating/monitoring that will remove the downed IP with TTL of 300 seconds will mean that it will take five minutes following a failure hen a system is actively accessing the site to transition. Reducing the TTL will speed up the transition at the expense of more frequent lookups.
DNS requests alternate the data returned
One query could have the response as ip1, ip2. After the TTL expires, a new query might get the response as ip2, ip1.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An enjoyable and seamless user experience can go a long way on an eCommerce site. While a cohesive layout and engaging copy play roles in creating a positive user experience, some sites neglect aspects that seem marginal but in actuality prove very …
Because your company can’t afford for you to make SEO mistakes, you’ll want to ensure you’re taking the right steps each and every time you post a new piece of content. This list of optimization do’s and don’ts can help you become an SEO wizard.
This video teaches users how to migrate an existing Wordpress website to a new domain.
Need to grow your business through quality cloud solutions? With everything required to build a cloud platform and solution, you may feel like the distance between you and the cloud is quite long. Help is here. Spend some time learning about the Con…

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now