[squid-users] Question on throughput
Amos Jeffries
squid3 at treenet.co.nz
Wed Oct 15 09:31:10 UTC 2014
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 15/10/2014 9:41 p.m., Jacques Kruger wrote:
> Hi,
>
> I've implemented my fair share of squid proxies over the past
> couple of years and I've always been able to find a solution in the
> mail archive, but this time around I'm stumped. This is the first
> time I've used squid with a fast (in our context) internet
> connection, specifically a 4G connection that the provider claims
> can run up to 100Mbps. Claims aside, my real-world testing is not
> what I'm expecting. I've used two squid instances, one on PFsence
> (2.7.9) and one on Windows (2.7Stable8) and compared the throughput
> to a connection without squid and what I've found is, when testing
> with www.speedtest.net<http://www.speedtest.net> the throughput is
> roughly half with squid compared to a direct connection. I've left
> to configuration pretty much default and have tried to tweak, both
> without success.
>
> What are the directives that have the most effect on throughput?
Not directives particularly, but on Windows the FD limit is fixed at an
absolute 2048, whereas non-Windows can exceed that by a few hundred
thousand or millions if needed.
It also depends on the NIC of the Squid machine. If that Windows box is
using a single NIC, then you will be maxing out the NIC capacity with
traffic going over it twice (client->Squid and Squid->Internet).
Then also the CPU gets a say. If the Squid is not doing much and the
CPU is very fast, Squid can end up running a lot of work cycles
transferring just one or a few bytes. Which impacts the TCP overheads
by decreasing bytes-per-packet.
It also depends on the protocol being used by the tests. In the modern
web there are HTTP/1.0, HTTP/1.1, WebSockets, HTTP/2, and SPDY capable
of being used for the test itself - the latter two of those involve
bandwidth comoression that can greatly enhance throughput. But only
HTTP/1.0 through default Squid-2.7 (HTTP/1.1 with tweaking).
PS. I would be interested to see what your results are with the
squid-3.3.3 now available for Windows via Cygwin.
Amos
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (MingW32)
iQEcBAEBAgAGBQJUPj7eAAoJELJo5wb/XPRj0WgH/iBxr/0CK+MMnL5PB/ZyANqx
uxazgxCsp+EDyxl2MR+iccsaerN/gdTM7Rzms1/PBlExk2yNQb8/6EUC8XQlJs8m
EEDI0lmd13jeVIWmXP2vYy1vQATuS7OMI0bvkfCDSI/bYVaHKMKCtssCPdQRKxul
akGgY7LhX7lLlkzgzrnrU8HUNN/PjFI7tg3y0xKihwEaDckYHcqg260cHJdjeI6C
2kZfFeJFMV0D0Y7N1HO38OKkJpHBIJoWDWWWlmI8j01UpsBSuxRqw51r1372jkne
Ka5m9vlQfGXWvI5Zg7uL3CxlBRTe6oe7T0n3dmHGy4KnvDbT09MXYMkS3ShTfzU=
=7UJb
-----END PGP SIGNATURE-----
More information about the squid-users
mailing list