Re: I think I have a memory leak in 2.3.x

Chuck Lever (cel@monkey.org)
Mon, 28 Jun 1999 16:25:05 -0400 (EDT)


On Mon, 28 Jun 1999, Jay Thorne wrote:
> I've been thinking about this more. Shrinking the inode cache, while it
> would be nice for "orthogonality" is not that important. The reason why it
> got out of hand on my system is that I set my inode cache far too large for
> my memory size. My fault, not the code.
>
> I have not looked at the code, but from empirical evidence, the inode cache
> can take a fair amount of memory per inode. I set my inode-max at 40690.
> Over time, the cache grew to nearly 10 megs. That was annoying since I only
> have 64megs. But the real answer is (Doctor Doctor, it hurts when I do
> this: So, don't do that).

heh. inodes are not too large anyway; you can fit 12 of them onto a
page. i don't see much advantage of actually shrinking the inode cache
the same way the buffer cache is shrunk. i tried a couple of little
experiments that suggested such a thing could only be bad for performance.

back to the memory leak. i think the late 2.3 kernels don't swap as
aggressively as earlier kernels did, and thus a lot of useful cached state
is shrink_mmap()'d away. even the 2.2 kernels don't swap as hard as they
ought to, IMO.

- Chuck Lever

--
corporate:	<chuckl@netscape.com>
personal:	<chucklever@netscape.net> or <cel@monkey.org>

The Linux Scalability project: http://www.citi.umich.edu/projects/linux-scalability/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/