Hi Willy, and thanks for your (quick) reply.
On Wed, Apr 16, 2008 at 7:45 PM, Willy Tarreau <w#1wt.eu> wrote:
> most likely you rely on a database which crawls under the I/O.
>
You're right.
It means that your servers sometimes do not even accept connections (maybe
> they were down, maybe they were totally saturated), and sometimes they did
> not
> respond within the timeout. The frontend request errors indicate invalid
> requests from clients. Such a huge number may indicate that your site is
> regularly attacked.
That could be, but i don't think so. I have applied your suggested configuration settings and although i don't see any errors in the webservers field, the errors for the Frontend field (Req) keep increasing. They're now over 800 with 45 minutes uptime of haproxy.
Your config is simple and correct. You may want to increase both
> clitimeout and srvtimeout so that haproxy leaves enough time to your
> application to respond. Ideally, both values should be equal. If your
> app sometimes needs one minute, put it slightly higher (80000 = 80s).
Done that, so that should (imo) get rid of most 504 HTTP errors, right?
If your servers are refusing connections because they are saturated,
> you may set a "maxconn" on the server lines. This value should be
> slightly lower than the "maxclients" you have configured on apache.
> Thus haproxy will act as a buffer between the clients and apache,
> preventing them from saturating. For instance :
>
> server webs001 x.x.x.11:80 cookie A maxconn 145 check
>
Done that too. Although i noticed that MaxClients had been increased to 1500, so i've set the haproxy maxconn to 1450.
regards,
> Willy
>
>
Well, let's see now what the customer says. I can't test it since the
problems don't continuously occur, so i'll have to rely on what visitors
experience.
I've inspected the website with YSlow and amongst other things we've noticed that with one visit to the frontpage of the site it makes approximately 60 HTTP requests to fully load it. Combine that with the fact that all images are stored in the database servers (ouch) and i wonder then if HAProxy is such a good solution for this particular situation. Please take no offense in this :) Maybe LVS is a better solution here?
Thanks for the help so far!
kind regards,
Sebastian. Received on 2008/04/17 11:58
This archive was generated by hypermail 2.2.0 : 2008/04/17 12:01 CEST