Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: Round robin DNS
PostPosted: Tue Feb 16, 2010 10:38 am 
Offline
Senior Newbie

Joined: Mon Feb 15, 2010 6:26 pm
Posts: 8
I'd like to implement a round robin DNS to distribute load between a two virtual web server instances. Is this as simple as adding an additional A record for the second instance in my DNS?

Joe


Top
   
 Post subject:
PostPosted: Tue Feb 16, 2010 10:42 am 
Offline
Senior Newbie

Joined: Mon Feb 08, 2010 5:09 pm
Posts: 17
Yes.


Top
   
 Post subject: Re: Round robin DNS
PostPosted: Tue Feb 16, 2010 11:28 am 
Offline
Senior Member

Joined: Sat Mar 28, 2009 4:23 pm
Posts: 415
Website: http://jedsmith.org/
Location: Out of his depth and job-hopping without a clue about network security fundamentals
jkinsell wrote:
I'd like to implement a round robin DNS to distribute load between a two virtual web server instances. Is this as simple as adding an additional A record for the second instance in my DNS?

Yes, but: If you have sessions, make sure a client can hit each of your Web servers and still have access to their session (potentially created on the other). Depending on the resolver, a client could flush cache and switch servers at any point.

_________________
Disclaimer: I am no longer employed by Linode; opinions are my own alone.


Top
   
 Post subject:
PostPosted: Tue Feb 16, 2010 11:37 am 
Offline
Senior Member
User avatar

Joined: Sat Aug 30, 2008 1:55 pm
Posts: 1739
Location: Rochester, New York
Also, it might not be a bad idea to drop the DNS TTL to a fairly low value. If one web server goes down, this will help you remove it from the rotation promptly. (Good load balancing segues nicely into good fault tolerance.)

Bonus points for using your monitoring system to update DNS automatically via the API. :-)


Top
   
 Post subject:
PostPosted: Tue Feb 16, 2010 11:19 pm 
Offline
Senior Member

Joined: Sun Aug 02, 2009 1:32 pm
Posts: 222
Website: https://www.barkerjr.net
Location: Connecticut, USA
You know what would be cool... If you could get your servers to talk to eachother and determine based on load if servers should be omitted from the pool for a bit to help lower load. This would be good if you staggered daily jobs so only one server ran them at a time.


Top
   
 Post subject:
PostPosted: Wed Feb 17, 2010 12:56 pm 
Offline
Senior Member
User avatar

Joined: Tue May 26, 2009 3:29 pm
Posts: 1691
Location: Montreal, QC
On a webserver, removing a server from the roundrobin to relieve load would result in that server having zero load after perhaps a second. Unless you intend to add/remove servers to the round-robin every few milliseconds, you couldn't balance load like that.

What you could do is have servers issue temporary redirects to other servers if the load was too high. A redirect is very light on the resources compared to loading a full blown dynamic site.

If each server has some way of knowing the load of each other server (perhaps each server updates their load in a database keeping the few records in a MEMORY table), they could issue redirects for requests to the server with the lowest load. Although at that point, you might as well just set up a dedicated load balancer.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group