hi,

Just checking if someone has any pointers. Please let me know

Thanks,
Vikram


On Tue, Jan 22, 2013 at 3:37 AM, Vikram Nayak <[email protected]>wrote:

> hi,
>
> I saw
> http://stackoverflow.com/questions/8750518/difference-between-global-maxconn-and-server-maxconn-haproxyand
>  that clarifies a lot of my doubts. But there is still some confusion
> whenever I look at haproxy-status. Please see if you can comment on the
> below. Or if there is a document which explains this, please point me to
> that.
>
> We are running a decent sized site. The config is slightly complicated so
> let me just take a relevant subset.
>
> There is a service which is handled by around 5 backend machines which are
> running apache. The apache server-status on those machines generally shows
> 200reqs/sec and around 200 child processes would be busy. So "ps -ef | grep
> httpd | wc -l" would give around 200. This is the prefork mode of apache.
>
> What confuses me is what frontend of haproxy-status shows. Let us just
> focus on "Cur" values of "session rate" and "sessions".  Here are the points
> 1. Invariably, for the frontend, the cur-sessions is almost 4-5 times the
> cur-sessionrate. Does this mean on an average a session is open by frontend
> with the client for 4-5 seconds? It seems pretty high to me. Is this
> governed by some configuration?
>
> 2. Now if I look at the backend and look at any of the 5 machines, I see
> that cur-sessions is almost the same as cur-sessionrate and they both are
> quite close to what apache server-status mentions as reqs/secs. So that
> seems to pass the gut check. The question now is if the backend servers
>  seem to keep a session for 1 sec, why is the frontend keeping it for
> 4-5seconds?
>
> 3. Lastly, I think this is outside the scope of HAProxy. But please advise
> if you are aware : I am pretty sure that the requests hitting backend
> apache are processed within 20-30milliseconds each. Each request returns a
> response which is a decently big xml file - around 20-30KB. The question
> now is why are 200 workers in apache busy (as per server-status) ? It
> implies there are 200 concurrent connections but then the processing will
> get over inside 20-30 milliseconds. So what are they doing for 1 second?
> Are they waiting till the 20-30KB XML file gets transferred via HAproxy to
> user's browser? Is there a way to free them up and let HAproxy take care of
> the transfer?
>
> Will be great if you can give some advice. We are running 1.4.20 on a
> Fedora 64-bit box.
>
> Thanks,
> Vikram
>

Reply via email to