Anybody interested in testing patch to allow weighted nodes?

Brett G. Durrett brett at
Thu May 17 13:30:43 UTC 2007

Okay, it sounds like most people are finding the optimal connections for 
a specific server and then limiting the connections on a server by 
server basis.  That makes sense.

Here is the problem where I thought weighing adds value.  Again, I may 
be thinking about this the wrong way so feedback from others is 

If I balance loads by limiting the number of connections to each machine 
to what is optimal for that machine, this should work great under 
"normal" conditions, especially since the pool of servers has enough 
available connections to handle the total number of backend connections 
and connections to spare.  However, sometimes our loads (and required 
back end connections) will dramatically change... maybe a code change 
unexpectedly requires more resources and bogs down servers or perhaps we 
just get a big surprise surge in usage and need to deploy more hardware 
to address the load.  In these cases where the total load (and required 
back end connections) is simply too great for each server to run 
optimally I have wanted the non-optimal loads to be shared among the 
pool relative to their ability to handle the load.  By limiting 
connections at the server level I would expect that in a load surge my 
servers would be at optimal loads but more requests would simply fail 
(as opposed to requests taking longer).  Of course we could setup 
scripts to look at the overall connections required and adjust each web 
server configuration dynamically if we exceed peak, but the simplicity 
of a Perlbal weighting mechanism seemed to work well in this particular 

To be clear, I am not arguing that weighting is the best solution or 
even the right solution, I am trying to explain where I think it can add 
value and find out from others how they address similar situations.  I 
would be quite happy to change my ways to something that works a lot better.



dormando wrote:
>> So my question to this mailing list is...  does the perlbal community 
>> see any value in having a weighting mechanism?  If the answer is no, 
>> I would love to hear how you are achieving the same effect and why 
>> your solution is your preferred mechanism.
>> Thanks in  advance for any constructive feedback,
> Twiddling values on the arrowpoint/bigip/netscaler/alteon/whatever is 
> something I don't miss. It's embarassing how bad an expensive 
> netscaler does its job compared to perlbal.
> I used to wish perlbal would allow me to specify the max connections 
> per node in the nodefile. Firstly to make it easier to twiddle the 
> settings without having to push config updates to dozens of servers. 
> Secondly so perlbal knows not to make an extra connect attempt if 
> you're at the limit already.
> But uh. We now have scripts that detect how fast a machine is, reduces 
> the number if it's running other services (mogstored, memcached), and 
> handles that magically now.
> Are you having an issue with connecting more often than necessary? 
> With almost 200 backend servers with 4-12 apache processes each, we're 
> only initiating new connections a couple times per second. Once you're 
> connected up the load just "flows" :) I've only ever had issues with 
> perlbal's backend connection mechanisms when something's breaking 
> keepalive.
> -Dormando

More information about the perlbal mailing list