RE: [squid-users] Slow connections

From: Ryan O'Rourke <[email protected]>
Date: Thu, 1 Aug 2002 15:44:17 -0500

Here is some information from the cachemgr and "top" sorted by memory usage
(like I said, this server gets very little use - and I have the cache
function disabled):

Connection information for squid:
        Number of clients accessing cache: 3
        Number of HTTP requests received: 330
        Number of ICP messages received: 0
        Number of ICP messages sent: 0
        Number of queued ICP replies: 0
        Request failure ratio: 0.00%
        HTTP requests per minute: 1.4
        ICP messages per minute: 0.0
        Select loop called: 39254 times, 371.647 ms avg
Cache information for squid:
        Request Hit Ratios: 5min: 0.0%, 60min: 0.6%
        Byte Hit Ratios: 5min: -0.0%, 60min: -0.0%
        Request Memory Hit Ratios: 5min: 0.0%, 60min: 100.0%
        Request Disk Hit Ratios: 5min: 0.0%, 60min: 0.0%
        Storage Swap size: 0 KB
        Storage Mem size: 1552 KB
        Mean Object Size: 0.00 KB
        Requests given to unlinkd: 0
Median Service Times (seconds) 5 min 60 min:
        HTTP Requests (All): 0.23230 1.24267
        Cache Misses: 0.23230 1.24267
        Cache Hits: 0.00000 0.15888
        Near Hits: 0.00000 0.00000
        Not-Modified Replies: 0.00000 0.00000
        DNS Lookups: 0.02336 0.09971
        ICP Queries: 0.00000 0.00000
Resource usage for squid:
        UP Time: 14588.639 seconds
        CPU Time: 2.810 seconds
        CPU Usage: 0.02%
        CPU Usage, 5 minute avg: 0.03%
        CPU Usage, 60 minute avg: 0.06%
        Maximum Resident Size: 0 KB
        Page faults with physical i/o: 320
Memory usage for squid via mallinfo():
        Total space in arena: 3924 KB
        Ordinary blocks: 3843 KB 37 blks
        Small blocks: 0 KB 0 blks
        Holding blocks: 176 KB 1 blks
        Free Small blocks: 0 KB
        Free Ordinary blocks: 80 KB
        Total in use: 4019 KB 102%
        Total free: 80 KB 2%
Memory accounted for:
        Total accounted: 1756 KB
        memPoolAlloc calls: 78913
        memPoolFree calls: 73216

And from top:

  2:45pm up 6:06, 1 user, load average: 0.00, 0.03, 0.00
43 processes: 41 sleeping, 2 running, 0 zombie, 0 stopped
CPU states: 0.3% user, 0.1% system, 0.0% nice, 99.4% idle
Mem: 29696K av, 27504K used, 2192K free, 0K shrd, 4300K
buff
Swap: 185464K av, 6060K used, 179404K free 10712K
cached

  PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND
 1404 nobody 15 0 5984 5984 1140 S 0.0 20.1 0:02 squid
 1103 apache 15 0 1760 1760 1528 S 0.0 5.9 0:00 httpd
 1104 apache 15 0 1760 1760 1528 S 0.0 5.9 0:00 httpd
 1105 a

So, would the fact that Squid is using 20% of the system memory as shown in
"top" and the fact that the "total in use" memory usage as shown in the
cachemgr is 102% indicate that Squid is using some swap? What other fields
are relevant here?

Also, using Links vs. IE or Netscape doesn't seem to make any difference on
the server running Squid or on a desktop machine behind the firewall.
Connection times, downloads, etc are on average 4 times faster when
connected directly to the Internet than when going through the proxy.

Any more help would be appreciated. Thanks for all you've done so far.

Ryan

> -----Original Message-----
> From: Joe Cooper [SMTP:joe@swelltech.com]
> Sent: Tuesday, July 30, 2002 10:31 PM
> To: Ryan O'Rourke
> Cc: squid-users@squid-cache.org
> Subject: Re: [squid-users] Slow connections
>
> What does the cachemanager have to say?
>
> Try:
>
> client mgr:info
>
> Check the service times for hits, misses, and DNS lookups at a time when
> things are slow.
>
> Check memory usage. Is there any chance Squid is going into swap, even
> just a little bit?
>
> Also check browsing from the proxy server itself to make sure there
> isn't some weird issue in your network that is affecting the proxy:
>
> lynx http://www.some-problem-site.com
>
> and to check it likewise through the proxy:
>
> client http://www.some-problem-site.com
>
> Is lynx noticeably faster than the client at retrieving the page
> (remembering that Lynx is a real browser, client is just a simple HTTP
> client with no HTML knowledge--a more accurate test would be to use wget
> with and without the proxy to retrieve some set of files a few times and
> compare the averages to see if Squid is the problem, or some other
> aspect of the proxies network configuration is to blame).
>
>
>
> Ryan O'Rourke wrote:
> > Well, I have looked into the possibility of DNS slowing down my squid,
> but
> > there don't seem to be any problems with it.
> > A look in the cache.log doesn't seem out of the ordinary to me (what is
> "FD
> > 4" though?):
> > [root@shirley cgi-bin]# cat /usr/local/squid/logs/cache.log |grep DNS
> > 2002/07/29 19:03:28| Performing DNS Tests...
> > 2002/07/29 19:03:28| Successful DNS name lookup tests...
> > 2002/07/29 19:03:28| DNS Socket created on FD 4
> > 2002/07/30 08:51:40| Performing DNS Tests...
> > 2002/07/30 08:51:40| Successful DNS name lookup tests...
> > 2002/07/30 08:51:40| DNS Socket created on FD 4
> > [root@shirley cgi-bin]# cat /usr/local/squid/logs/cache.log |grep dns
> > 2002/07/30 08:51:15| CACHEMGR: root@127.0.0.1 requesting 'idns'
> > 2002/07/30 08:53:46| CACHEMGR: root@127.0.0.1 requesting 'idns'
> > [root@shirley cgi-bin]#
> >
> > Any other suggestions?
> > Thank you.
> > Ryan
> >
> >
> >>-----Original Message-----
> >>From: Joe Cooper [SMTP:joe@swelltech.com]
> >>Sent: Monday, July 29, 2002 12:16 PM
> >>To: Ryan O'Rourke
> >>Cc: squid-users@squid-cache.org
> >>Subject: Re: [squid-users] Slow connections
> >>
> >>
> >>Check your cache.log, access.log and cachemgr for clues about where
> >>things are slowing down. DNS is often the culprit when someone in your
> >>situation (i.e. very few users) says "My Squid is slow".
> >>
> >>
> >
>
>
>
> --
> Joe Cooper <joe@swelltech.com>
> Web caching appliances and support.
> http://www.swelltech.com
Received on Thu Aug 01 2002 - 14:42:40 MDT

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