Re: servers shared amongst backends

From: Ben <midfield#gmail.com>
Date: Sat, 24 Jul 2010 13:13:28 -0700


Thanks for the quick reply. I will look forward to release 1.5 or 1.6. Is there a (very rough) ETA on those releases?

Best regards, Ben

On Fri, Jul 23, 2010 at 10:35 PM, Willy Tarreau <w#1wt.eu> wrote:
> Hello Ben,
>
> On Fri, Jul 23, 2010 at 03:21:03PM -0700, Ben wrote:
>> Hello --
>>
>> I've searched for this on the mailing list but I haven't found an
>> answer, hope someone can help!
>>
>> I have a setup like
>>
>> 5 machines (m1,..,m5)
>> 2 services (s1, s2)
>>
>> Each machine has one or both of the services, each instance of each
>> service is identical.  I want to present each service as a single
>> entity, but I'd also like to limit the maximum number of connections
>> to the machines.  The obvious way to do it would be to set up two
>> backends in the configuration, one which points to all the machines
>> which have s1, the other to the machines with s2.  But there will be
>> some overlap in the machines, so the machines might get overloaded
>> with connections (if I keep the maxconn parameter the same in each
>> backend) or else be underutilized (if i split the connections between
>> the backends, and only one service is being requested.)
>>
>> For concreteness suppose my setup is
>>
>> m1, m2, m3 have s1
>> m2, m3, m4, m5 have s2
>> (so m2,m3 have both services.)
>>
>> Is it possible to have server (with maxconn) shared between backends?
>
> No, this is something which is planned for version 1.6 but which *may*
> finally get into 1.5 if it happens to be easier than initially thought.
> Your example is interesting BTW, because your backends are heterogenous,
> so it proves that the association must clearly be between individual
> servers.
>
>> Or is there another way to accomplish my goal?
>
> Not really. When backends are similar, it's quite common that people
> use a same backend for both services, assuming there's little or no
> risk of losing one service without the other one. If yours are different,
> then I would still suggest to have two backends with half of the maxconn
> in each (or slightly higher if you know that both services are not really
> saturated at the same time). While this can be perceived as having
> underutilized servers, it's not true in practice, because the maxconn
> you set indicates the limit the server cannot handle. It does not mean
> the server cannot be full far below. For instance, I know some people
> who set their apache to a very low maxconn of 30, because it's the level
> they observe the best performance for their app. But the servers are
> configured with MaxClients 256, so you can fully use them with any value
> between 30 and 256. That means that one backend at 30 will be able to
> saturate them, and two backends at 30 too, without risking stability.
>
> In fact, the only case where this is not really possible is with mongrel
> which has a maxconn of 1 that you can't split !
>
> Best regards,
> Willy
>
>
Received on 2010/07/24 22:13

This archive was generated by hypermail 2.2.0 : 2010/07/24 22:30 CEST