Re: [squid-users] [reverse proxy] ESTABLISHED on squid server

From: Le Trung Kien <kienlt_at_vietnamnet.vn>
Date: Thu, 23 Jun 2011 08:44:21 +0700

Thank you, Amos, for your very clear answer.

On Wed, Jun 22, 2011 at 7:51 PM, Amos Jeffries <squid3_at_treenet.co.nz> wrote:
> On 22/06/11 22:54, Le Trung, Kien wrote:
>>
>> Hi, I trouble about how to reduce the ESTABLISHED statuses of connections.
>> It always have approximately 6300 ESTABLISHED connections when server
>> at high load time of the day and just reduce below 1000 ESTABLISHED in
>> the midnight.
>>
>>       1 established)
>>       1 Foreign
>>       5 FIN_WAIT2
>>       6 LISTEN
>>      11 CLOSING
>>      43 SYN_RECV
>>      63 LAST_ACK
>>     237 FIN_WAIT1
>>    1331 TIME_WAIT
>>    6258 ESTABLISHED
>>
>> I wonder how to free the connection after data all been tranferred
>> between squid server and clients. (I think squid keeps connections as
>> much as possible).
>
> Depends on which Squid you have. 3.1 and later try to use HTTP/1.1 features
> to speed up client access times. These require persistent connections.
>
> ~6300 connections is not bad. Your box can handle far more than that easily.
>
>> On another web  server (same operating system and hardware, etc ...)
>> which has the same connections to (because of DNS round-robin) the
>> ESTABLISH connections are range from 2000-3000.
>
> This is not a valid comparison. see:
> http://wiki.squid-cache.org/Features/LoadBalance#Bias:_Connection-based
>
> This same problem affects DNS round-robin and TCP SYN load balancers. Which
> are also per-connection.
>
>
>
> Generally speaking ESTABLISHED is good. They are either currently in active
> use or waiting and will have zero TCP connection setup delay when they are
> needed.
>
> The more recent your Squid version number the more efficiently it handles
> persistent connections. Thus the lower number it uses. So if this is
> actually a problem for you a newer version is better.
>
> You can also adjust it by tweaking the idle_timeout directive. Which
> determines a maximum amount of time any one connection can be kept waiting.
>
> You can disable the persistence and all HTTP features which rely on it by
> configuring client_persistent_connections and/or
> server_persistent_connections OFF.
>
> Amos
> --
> Please be using
>  Current Stable Squid 2.7.STABLE9 or 3.1.12
>  Beta testers wanted for 3.2.0.9 and 3.1.12.3
>
Received on Thu Jun 23 2011 - 01:44:30 MDT

This archive was generated by hypermail 2.2.0 : Thu Jun 23 2011 - 12:00:02 MDT