Is possbile automatically normal server connection after web server down?

WebReactor Networks bind at webreactor.net
Wed Feb 27 16:21:27 UTC 2002


How about something like this (below)?  It's a little funky, but does anyone
see any reason why a little daemon like this wouldn't work?  - John R. S.


#!/bin/sh
#
typeset -i status

domain_name="www.domain.tld"
active_ip=1.1.1.1
standby_ip=2.2.2.2

function update_the_dns {
  {
    echo "update delete $1 IN A"
    echo "update add $1 60 IN A $2"
    echo ""
  } | nsupdate
}

update_the_dns $domain_name $active_ip

while true; do # repeat forever

  wget http://$domain_name/test.html >/dev/null 2>&1
  status=$?        
  if [ $status -ne 0 ]; then
    tmp_ip=$active_ip
    active_ip=$standby_ip
    standby_ip=$tmp_ip
    update_dns $domain_name $active_ip
  fi
  sleep 60

done


 

----------
From: <arvid at carlander.ac>
Organization: Posted via Supernews, http://www.supernews.com
Reply-To: <arvid at carlander.ac>
Newsgroups: comp.protocols.dns.bind
Date: Wed, 27 Feb 2002 09:51:56 -0000
To: comp-protocols-dns-bind at isc.org
Subject: Re: Is possbile automatically normal server connection after web
server down?


"jenny" <mjjung at gngidc.net> wrote in message
news:a5hs0b$dap at pub3.rc.vix.com...
>
> hi~all.
> we using BIND 8.2.4 on solaris 5.7.
>
> I wonder the following senario is possible.
>
>
> location : A, B(for Disaster Recovery)
> Each location's network is another network.
>
> Location A : web server-org (1.1.1.1)
> Location B : web server-bk  (2.2.2.2 )
>
> if original web server(1.1.1.1) down at A , web server autoimatically
starts
> via backup web server(2.2.2.2).
>
>
> Is possbile above senario ?
> if possbile, how to configure nameserver for above senario?
>

Using Bind you can map both IP addresses to the same domain name and URL.
This will result is rudimentary load sharing between your two web servers.
It will not, however, avoid the situation where some of your users try to
connect to a web server that is down.

To get the failover you need you should look at a commercial name server
capable of determining which of your web servers are operational and
resolving your domain names accordingly. There are many manufacturers in
this market, and you might start with F5 or Cisco.

-Arvid
>
> thanks.
>






More information about the bind-users mailing list