Re: [K12OSN] squid box can't handle load

Eric Harrison (eharrison@mail.mesd.k12.or.us)
Mon, 3 Feb 2003 08:08:30 -0800 (PST)


On Mon, 3 Feb 2003, Mike Rambo wrote:

>Heath Henderson wrote:
>> 
>> Squid should be able to handle that kind of load easily though.
>> 
>> How many computers are making connections to this machine?
>> 
>
>We have 43 buildings - possibly a potential for 4000-6000 users at any
>given time (as a rough guess).
>
>I ran a top after I first posted and found...
>
>> 
>>   9:09am  up 2 days,  9:55,  3 users,  load average: 2.44, 2.36,
>> 2.29                                              57 processes: 54
>> sleeping, 3 running, 0 zombie, 0 stopped
>> CPU states:  6.9% user, 93.0% system,  0.0% nice,  0.0% idle
>> Mem:   255908K av,  252448K used,    3460K free,       0K shrd,   30588K
>> buff
>> Swap:  526296K av,       0K used,  526296K free                  153784K
>> cached
>> 
>>   PID USER     PRI  NI  SIZE  RSS SHARE STAT %CPU %MEM   TIME COMMAND
>>  8146 squid     25   0 12668  12M  1252 R    71.4  4.9   3:50 squid
>>  8152 squid     15   0  2112 2112   688 S     2.7  0.8   0:06 squidGuard
>>  8154 squid     15   0  2076 2076   688 S     1.7  0.8   0:06 squidGuard
>>  8165 squid     16   0  2064 2064   688 S     1.7  0.8   0:04 squidGuard
>>  8160 squid     15   0  2088 2088   688 S     1.5  0.8   0:05 squidGuard
>>  8183 root      16   0  1044 1044   848 R     1.5  0.4   0:00 top
>>  8149 squid     15   0  2104 2104   688 S     1.3  0.8   0:06 squidGuard
>>  8150 squid     15   0  2092 2092   688 S     1.3  0.8   0:05 squidGuard
>>  8151 squid     15   0  2104 2104   688 S     1.3  0.8   0:07 squidGuard
>>  8153 squid     15   0  2100 2100   688 S     1.3  0.8   0:05 squidGuard
>>  8159 squid     16   0  2104 2104   688 S     1.3  0.8   0:05 squidGuard
>>  8161 squid     15   0  2104 2104   688 S     1.3  0.8   0:05 squidGuard
>>  8148 squid     15   0  2092 2092   688 S     1.1  0.8   0:07 squidGuard
>>  8158 squid     15   0  2084 2084   688 S     1.1  0.8   0:05 squidGuard
>>  8166 squid     15   0  2080 2080   688 S     1.1  0.8   0:03 squidGuard
>>     3 root      34  19     0    0     0 RWN   0.9  0.0   2:17
>> ksoftirqd_CPU0
>>  8147 squid     15   0  2100 2100   688 S     0.9  0.8   0:09 squidGuard
>>  8156 squid     15   0  2088 2088   688 S     0.9  0.8   0:05 squidGuard
>>  8157 squid     15   0  2104 2104   688 S     0.9  0.8   0:05 squidGuard
>>  8155 squid     15   0  2080 2080   688 S     0.7  0.8   0:05 squidGuard
>>  8163 squid     15   0  2096 2096   688 S     0.7  0.8   0:04 squidGuard
>>  8164 squid     15   0  2092 2092   688 S     0.7  0.8   0:04 squidGuard
>>   144 root      15   0     0    0     0 SW    0.5  0.0   0:05 kjournald
>>  8162 squid     15   0  2076 2076   688 S     0.5  0.8   0:05 squidGuard
>>     1 root      15   0   480  480   420 S     0.0  0.1   0:08 init
>>     2 root      15   0     0    0     0 SW    0.0  0.0   0:00 keventd
>>     4 root      15   0     0    0     0 SW    0.0  0.0   0:09 kswapd
>> 
>
>
>It would appear the box isn't fast enough for the load. I did a service
>ipchains stop to remove the port 80 redirection to squid and internet
>access has returned to normal. Of course filtering is off line now too.
>
>
>Mike

We're running ~100 sites on five boxes, each with a PIII 550, 512M ram,
20 Gig IDE drives. We have run fine on as few as three of these servers,
we'd probably be ok with two.

Caches are memory sensitive, you will want more than 256M.

For squid configuration, here's my entries that are relevent to performance:

	cache_mem  300 MB
	maximum_object_size 16384 KB
	cache_replacement_policy heap LFUDA
	memory_replacement_policy heap LFUDA
	cache_dir diskd /var/spool/squid 15000 30 256
	cache_store_log none
	half_closed_clients on

-Eric



_______________________________________________
K12OSN mailing list
K12OSN@redhat.com
https://listman.redhat.com/mailman/listinfo/k12osn
For more info see