Thanks to all for the help. Below is the output of free. The numbers below
are in mb, not kb.
[svn@svn svn]$ free -t -m -l
total used free shared buffers cached
Mem: 1133 1122 10 0 114 764
Low: 877 869 8 0 0 0
High: 255 253 2 0 0 0
-/+ buffers/cache: 244 888
Swap: 1992 13 1978
Total: 3125 1136 1988
Here is the output of ps (ps version 2.0.11 on kernel 2.4.20-6)
[svn@svn svn]$ ps -aux |grep httpd
svn 4192 0.0 0.1 5032 1952 ? S Jan22 0:00
/usr/local/apache2/bin/httpd -k start
svn 4193 0.0 1.0 15460 12452 ? S Jan22 0:07
/usr/local/apache2/bin/httpd -k start
svn 4195 0.0 2.2 30120 26092 ? S Jan22 0:24
/usr/local/apache2/bin/httpd -k start
svn 4196 0.0 0.7 11768 8356 ? S Jan22 0:02
/usr/local/apache2/bin/httpd -k start
svn 4197 0.0 1.8 24984 21416 ? S Jan22 0:15
/usr/local/apache2/bin/httpd -k start
svn 4207 0.0 1.3 18736 15540 ? S Jan22 0:04
/usr/local/apache2/bin/httpd -k start
svn 4208 0.1 1.9 25980 22308 ? S Jan22 1:15
/usr/local/apache2/bin/httpd -k start
svn 4311 0.0 1.6 21664 18592 ? S Jan22 0:16
/usr/local/apache2/bin/httpd -k start
svn 5550 0.0 1.1 15712 13020 ? S 10:12 0:00
/usr/local/apache2/bin/httpd -k start
svn 5553 0.0 0.6 9996 7156 ? S 10:12 0:00
/usr/local/apache2/bin/httpd -k start
svn 5556 0.0 0.2 5560 3428 ? S 10:13 0:00
/usr/local/apache2/bin/httpd -k start
svn 5635 0.0 0.0 3568 624 pts/0 S 11:40 0:00 grep httpd
Thanks,
Ryan
-----Original Message-----
From: Tobias Ringstrom [mailto:tobias@ringstrom.mine.nu]
Sent: Friday, January 23, 2004 8:56 AM
To: rbraswell@connected.com
Cc: users@subversion.tigris.org
Subject: Re: httpd sucking up memory
rbraswell@connected.com wrote:
> I just upgraded to 0.36 and the bleeding continues.
>
> Prior to starting apache after the upgrade to 0.36
> Free memory was 779512k
> Free swap was 2031040k
>
> After the upgrade to 0.36, apache was started
> Free memory was 779000k
> Free swap was 2031040k
>
> After doing a checkout from the newly upgraded 0.36 repository
> Free memory was 653544k
> Free swap was 2031040k
As Jan Evert said, this does not say much. Most of the free memory that
has "disappeared" is used as disc cache and will be freed once
applications need it. The info from ps below is much more interesting.
> Also, look at the memory usage by httpd here.
>
> [svn@svn bin]$ ps -uaxww | grep httpd
> svn 4192 0.0 0.2 5032 2356 ? S 21:54 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4193 0.0 0.2 5368 3348 ? S 21:54 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4194 0.0 0.4 8172 5456 ? S 21:54 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4195 0.6 2.1 29084 24824 ? S 21:54 0:23
This process is larger than the others, probably because you have only
performed one checkout, and this process is the one who talked to the
client. The size is a bit on the big side, but it's not *that* big.
> /usr/local/apache2/bin/httpd -k start
> svn 4196 0.0 0.2 5320 3280 ? S 21:54 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4197 0.0 0.2 5300 3228 ? S 21:54 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4207 0.0 0.2 5320 3264 ? S 21:59 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4208 0.0 0.3 6232 3876 ? S 21:59 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4209 0.0 0.2 5320 3280 ? S 21:59 0:00
> /usr/local/apache2/bin/httpd -k start
> svn 4293 0.0 0.0 3568 624 pts/0 S 22:54 0:00 grep httpd
>
> To reproduce this problem, simply use svn via apache. You will see the
> memory get chewed up, and then on to the swap space until the whole
> thing grinds to a halt!
Are you saying that the httpd processes are growing slowly over time?
The memory bugs normally show up during a specific access, such as
import of a directory with lots and lots of files in it. That specific
access would cause the httpd process to grow to hundreds of megabytes.
(That was just an illustration if course. There is no such bug.)
It is normal for the httpd processes to not shrink in the ps listing
between access, so the size you see in ps normally grows during the
first few access and then stop growing. In other words, the size you see
is the peek memory usage so far in the lifetime of that process.
So we need to know if httpd indeed grows between accesses or not. If
there is a specific access that causes httpd to grow, we need to know
exactly what access that is.
/Tobias
Received on Fri Jan 23 19:33:50 2004