On Fri, May 02, 2008 at 01:40:22AM +0300, Axel Thimm wrote:
> On Thu, May 01, 2008 at 11:26:54PM +0100, John Robinson wrote:
> > On 01/05/2008 22:57, Axel Thimm wrote:
> > > On Thu, May 01, 2008 at 10:46:34PM +0100, John Robinson wrote:
> > >> Apache isn't really all that much of a memory hog.
> > [...]
> > > top says ~500m VIRT
> > 
> > Eh? 500m each? WT* are you doing with your Apache config?
> > 
> > > and ~60m RES, I take it that each process eats
> > > about 60m.
> > 
> > Nope. Have a look at SHR, you can subtract all that too. Even then it's 
> > probably over; try some experiments with ps and adding up what it says:

Oh, I forgot to mention the SHR. top says:

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND            
12658 apache    15   0  535m  59m 8232 S    2  1.3   0:06.79 httpd              
17782 apache    15   0  406m  16m 3184 S    0  0.4   0:00.02 httpd              
18259 apache    15   0  531m  62m 8248 S    0  1.4   0:13.90 httpd              
12653 apache    15   0  536m  67m 8204 S    4  1.5   0:16.07 httpd              
 8455 apache    15   0  518m  48m 8008 S    0  1.1   0:01.62 httpd              
12653 apache    15   0  536m  67m 8204 S    4  1.5   0:16.19 httpd              
17780 apache    16   0  499m  27m 6064 R   12  0.6   0:00.36 httpd              

When I mentioned the 60/500MB usage I had top sorted by memory, so I
didn't see the 16m and similar low fat httpds. I guess the stats will
add up to the 32m mentioned below.

> > Doesn't make sense to me...
> 
> OK, I tried
> 
> # ps -e --no-headers -o vsz,cmd|grep httpd| wc -l
> 111
> # ps -e --no-headers -o vsz,cmd|grep httpd|(j=0; while read i c ; do j=`expr 
> $i + $j` ; done ; echo $j)
> 40752756
> # ps -e --no-headers -o rsz,cmd|grep httpd|(j=0; while read i c ; do j=`expr 
> $i + $j` ; done ; echo $j)
> 3569776
> 
> So it's about 32MB/360MB real/virtual just as you said in the beginning.
-- 
Axel.Thimm at ATrpms.net

Attachment: pgpB9OCouwzM5.pgp
Description: PGP signature

_______________________________________________
atrpms-users mailing list
[email protected]
http://lists.atrpms.net/mailman/listinfo/atrpms-users

Reply via email to