[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Source of memory leak in mod_proxy?

From: Cliff Woolley <jwoolley_at_virginia.edu>
Date: 2002-09-05 04:11:13 CEST

On Wed, 4 Sep 2002, Greg Stein wrote:

> bb = apr_brigade_create(r->pool, r->connection->bucket_alloc); Does
> that allocator somehow use connection memory? Maybe we have some kind of
> leak between the request-based brigade and the connection-based
> allocator? [ I don't know enough about the bucket allocator stuff ]

The purpose is supposed to be that, over the course of the connections for
which the allocator is used, you reach a steady state where n-bytes are
the most needed at one time. Unlike the connection pool, the
c->bucket_alloc reuses memory as buckets get freed.

Bottom line: the size of c->bucket_alloc will be based on the max number
of buckets and bucket buffers you've had allocated at one time. The
answer is almost certainly that apr_bucket_destroy() is not being called
on some bucket that you're actually finished with. This could be a
symptom of discarding a brigade that still has buckets in it (since
apr_brigade_destroy() will destroy all the buckets that are in the brigade
at the time of the brigade's destruction), which is, I believe, what you
guys have said is happening in this case.


To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Sep 5 04:13:27 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.