Right. I understand this method - and we have this segmented using VLAN's
w/ a LB machine inbetwen holding the single IP w/ several machines behind
it.
What I was wondering is using a different model, DNS load balancing, where
the decision comes from to decide which IP to pull. We use DJBDNS and this
information seemed to indicate the client made the decision. However, in
doing some ping tests on several machines it seems that it is actually
handing out sequential IPs. Just not fmailiar with what is going on behind
the scenes and wanted to make sure that when using ASP to pull a web service
via HTTP the behavior would be the same.
How to balance load among many web servers
These instructions assume that you are already running tinydns, version 1.04
or later, as a DNS server.
Suppose you have 50 identical
www.heaven.af.mil web servers running on IP
addresses 1.2.3.150, 1.2.3.151, and so on. You can simply list all their
addresses in /service/tinydns/root/data:
+
www.heaven.af.mil:1.2.3.150
+
www.heaven.af.mil:1.2.3.151
+
www.heaven.af.mil:1.2.3.152
# etc.
When a DNS cache asks for the IP address of
www.heaven.af.mil, tinydns will
automatically return a random set of 8 addresses.
If one of your web servers crashes, the effect on users will depend on how
their browsers behave:
a.. Silly behavior: I've heard rumors of obsolete browsers that give up
after a single IP address.
b.. Standard behavior: Most browsers move on to the next IP address after
the first connection attempt times out. A server outage produces a long
delay but not a failure.
c.. Smart behavior: To reduce the delay, smart browsers try each address
with a two-second timeout before retrying each address with a long timeout.
You can eliminate delays by removing IP addresses of web servers that have
crashed. tinydns is designed to work with external programs that monitor the
health of your servers. Specify each address with a 5-second TTL:
+
www.heaven.af.mil:1.2.3.150:5
+
www.heaven.af.mil:1.2.3.151:5
+
www.heaven.af.mil:1.2.3.152:5
An external program can remove an address by simply changing + to - on the
relevant line, then running make. Later, when that server has recovered, the
program can change - back to +.