[squid-users] trouble w/ delay_pools info in cachemgr

From: Adam <adam-s@dont-contact.us>
Date: Mon, 12 May 2003 13:39:30 -0700

Hello all,

I am trying to understand some of the values in the Cachemgr scripts
delay_pools sub-menu.

One question I have is what does "Current mean" in the following:
Pool: 1 Class: 2
     Aggregate:
            Max: 206000
            Restore: 206000
            Current: 206000
Does "Current: 206000" mean that this pool is maxed out/using the full
alloted bandwidth? I.e. using the maximum aggregate size I defined (20600)?

I ask because one of the other pools has a lower value:
               Max: 206000
               Restore: 206000
              Current: 199932

So I just wanted to confirm that that meant this 2nd delay_pool is using
just shy of the max that I set.

Also what does the 1st (lefthand) number in a pair under "Individual" like
this "Current: 31:51200 128:45551 38:51200 etc." represent? The second
number is my bucket/threshold size. I summed all the first numbers
(###:...) for each of my delay pools and the numbers don't really add up to
anything I understand. For delay_pool 3, which is set to a Max of 51200, a
Rate of 3200 and has 212 #:# entries, the lefthand side numbers sum up to
26385 so I thought they represented how many bytes each connection was
getting. However the main daytime delay_pool (#4) has 256 such #:# entries
adds up to 32556 while the rate for that pool is 16000 and the max or bucket
is 51200. So what is the first number represent? I had thought (hoped)
maybe it correlated to the socket listed in the filedescriptors menu but
they don'tmatch (e.g. there is a 1:## and a 2:## and no such socket in the
fd menu).

Is there any way to correllate these delay_pool entries to either the access
log file or filedescriptor menu so I can verify/compare my totals?

Also one time (but not everytime) I pulled up this menu, the Current: field
for delay_pool #4 was equal to -20. I only found one explanation on the
mailing list of this value and it was good but I don't quite understand it:
http://groups.google.com/groups?selm=82f6dq%245ni%241%40FreeBSD.csie.NCTU.ed
u.tw wrote:

" OK, negative values mean the pool is currently being delayed. Due to the
way squid works, if a pool has 19 active clients and a balance of 1 byte, it
will
select all these clients for reading. Then, when it reads from the clients,
it will never ask for less than 1 byte, so it would read 1 byte from each
client connection. Hence the balance can be negative. If the balance is
zero or negative, requests are at this instant not being selected for
reading."

What I don't understand is why this value wouldn't always be negative since
the pools are *always* being delayed since they are delay pools. Or does he
mean they are maxed out? Then why wouldn't they just say the max value,
like the first example of "Current: 20600" I posted above does? Also I
don't understand what he means by "a balance of a byte." And if by "not
being selected for reading" he means these are idle connections then
wouldn't they be dropped from the delay_pool and a new connection started
later? If someone can either correct or clarify this explanation or provide
their own for "-20" I would greatly appreciate it.

One of the reasons I am digging around is: I don't know if my delay_pool
acls are working correctly. Theoretically few to none should be in the1st
or 3rd delay_pools since they are site specific (delay_pool #1) and
off-hours (#3). Pool #2 (vip's) looks about right since it is 4-5
connections. So I am wondering, since delay_pool #3 runs until 8am, if a
user starts a connection before 8am, would it then stay persistent 4 hours
later (it's after noon)? Do delay_pools remember that person's IP even if
it is a non-persistent normal grabbing of a web page? I can see for
persistent connections but it is hard to believe there are 212 such
persistent connections, especially when the filedescriptors menu doesn't
seem to show that many streaming/radio type persistent connections at the
moment.

Lastly, what is the significance of the value at the very bottom: "Memory
used" - since I've been watching this menu wavers around 6048 and 5464 bytes
which in either case seems pretty tiny and doesn't add up to any of the
numbers on the screen. Currently there is 1024MB of RAM with 183MB free,
and 602MB swap in use. The squid process is 584MB (581MB resident).

thanks for any tips both about the values in this menu and why some
delay_pools which should currently be inactive might be running/in use now.

thanks,

Adam

P.S. Here are some of my config params:
acl delayed time MTWHF 8:01-17:30
acl notdelayed3 time SMTWHFA 17:31-23:01
acl notdelayed3 time SA 8:01-17:30
acl notdelayed3 time SMTWHFA 0:02-8:00
acl notdelayed2 src 192.168.2.1
# vip group1 (the boss)
acl notdelayed2 src 192.168.2.12 192.168.2.140 192.168.2.4 # vip group2
(admins)
acl notdelayed2 src 192.168.6.2 192.168.6.3 192.168.6.1 # vip
group3 (users)
acl notdelayed1 urlpath_regex -i \.pdf$ \.doc$
# faster downloads for docs
acl ourwebserver dstdomain www.ourwebserver.com # from
our own public website

delay_pools 4
delay_class 1 2
delay_class 2 2
delay_class 3 2
delay_class 4 2
delay_access 1 allow ourwebserver notdelayed1
delay_access 1 deny all
delay_access 2 allow notdelayed2
delay_access 2 deny all
delay_access 3 allow notdelayed3
delay_access 3 deny all
delay_access 4 allow delayed
delay_access 4 deny all
delay_parameters 1 206000/206000 28000/51200
delay_parameters 2 206000/206000 30000/51200
delay_parameters 3 206000/206000 32000/51200
delay_parameters 4 206000/206000 16000/51200
Received on Mon May 12 2003 - 14:40:32 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:16:36 MST