Squid 2.2.5 is too heavyweight.
Hello, I have the squid (Version: 2.2.5-3) packaged on my system.
I have a P2-450 which I use as a personal workstation. Due to the
braindeadness of the netscape http-cache, I run my http/ftp clients
through squid, which works out pretty good. It drops off most
advertisements, and acts as a useful funnel.
I came from a P166, Redhat 5.2 system , which has squid (version: 1.1.22)
installed. That was a very nice system. It was lightweight and small. The
current version (2.2.5) on potato is heavyweight in comparison, 16
threads, twice the memory, and several times the CPU overhead.
Here are a couple of comparisons between them:
Both computers have had an uptime of 9 hours..
The old one (a P166) has had no queries and runs a cache of 95mb. It
has only used 2 seconds of CPU time in that period..
>>>
[crosby@hypercube crosby]$ ps S `pidof squid`
PID TTY STAT TIME COMMAND
412 ? S 0:02 squid
<<<
The new computer with debian (the P2-450), has a cache size of 130mb. It
has had a total of 548 queries in those 9 hours. But yet, the CPU time is
over 50 minutes, almost 1/10 of the CPU dedicated to that one program
which has deleted no cache entries, and served an average of 1.1 hits
per second, and handled 5mb of traffic.
Not only that, but even when it is idle and completely unused, its still
using over 10% of the CPU.... (See statistics below)
>>>
crosby@dragonlight:/home/crosby# uptime
5:40am up 8:41, 15 users, load average: 0.07, 0.05, 0.05
crosby@dragonlight:/home/crosby# ps 314 ; sleep 60s ; ps 314
PID TTY STAT TIME COMMAND
314 ? S 50:24 (squid) -D -sYC
PID TTY STAT TIME COMMAND
314 ? S 50:31 (squid) -D -sYC
crosby@dragonlight:/home/crosby# ps axfS
...
312 ? S 0:00 /usr/sbin/squid -D -sYC
314 ? S 51:38 \_ (squid) -D -sYC
315 ? S 0:19 \_ (squid) -D -sYC
316 ? S 0:00 | \_ (squid) -D -sYC
317 ? S 0:00 | \_ (squid) -D -sYC
318 ? S 0:00 | \_ (squid) -D -sYC
319 ? S 0:00 | \_ (squid) -D -sYC
320 ? S 0:00 | \_ (squid) -D -sYC
321 ? S 0:00 | \_ (squid) -D -sYC
322 ? S 0:00 | \_ (squid) -D -sYC
323 ? S 0:00 | \_ (squid) -D -sYC
324 ? S 0:00 | \_ (squid) -D -sYC
325 ? S 0:00 | \_ (squid) -D -sYC
326 ? S 0:00 | \_ (squid) -D -sYC
327 ? S 0:00 | \_ (squid) -D -sYC
328 ? S 0:00 | \_ (squid) -D -sYC
329 ? S 0:00 | \_ (squid) -D -sYC
330 ? S 0:00 | \_ (squid) -D -sYC
331 ? S 0:00 | \_ (squid) -D -sYC
332 ? S 0:00 \_ (dnsserver)
333 ? S 0:00 \_ (dnsserver)
334 ? S 0:00 \_ (dnsserver)
335 ? S 0:00 \_ (dnsserver)
336 ? S 0:00 \_ (dnsserver)
337 ? S 0:09 \_ (pinger)
...
<<<
The cause seems to be polling every 20ms (for some reason), despite the
fact that nothing is happening.
>>>
gettimeofday({949920173, 951863}, NULL) = 0
poll([{fd=34, events=POLLIN}, {fd=35, events=POLLIN}, {fd=37,
events=POLLIN}], 3, 10) = 0
gettimeofday({949920173, 972986}, NULL) = 0
poll([{fd=34, events=POLLIN}, {fd=35, events=POLLIN}, {fd=37,
events=POLLIN}], 3, 10) = 0
gettimeofday({949920173, 992163}, NULL) = 0
poll([{fd=34, events=POLLIN}, {fd=35, events=POLLIN}, {fd=37,
events=POLLIN}], 3, 10) = 0
gettimeofday({949920174, 12160}, NULL) = 0
poll([{fd=34, events=POLLIN}, {fd=35, events=POLLIN}, {fd=37,
events=POLLIN}], 3, 10) = 0
gettimeofday({949920174, 31838}, NULL) = 0
poll([{fd=34, events=POLLIN}, {fd=35, events=POLLIN}, {fd=37,
events=POLLIN}], 3, 10) = 0
<<<
Even if squid is acting pathological in this case, the new version is
still much heavier than the last one. Even if it is better for large
caches on dedicated machines, I suspect that most of the installs of
squid for debian will be for small caches on private lans that share a
dialup link.
So, could the previous version (1.1.22) of squid be packaged up and added
to the debian/potato as an alternate to using version 2.2.5?
Thanks.... Scott.
Reply to: