Memory Leak Issues

Matt Kettler mkettler at evi-inc.com
Wed Oct 25 16:39:47 IST 2006


Kaplan, Andrew H. wrote:
> Hi there --
> 
> I am running Fedora Core 5 that was hardened by Bastille Linux on a system with
> 1.5 GB of RAM. The system functions as an e-mail server running Sendmail 8.13.7,
> 
> along with MailScanner 4.55.9, SpamAssassin 3.1.0, and ClamAV 0.88.5. 
> 
> I have noticed over time, via the free -m command, that the amount of cached RAM
> is going up. This results in the amount of free memory going down to where there
> is almost nothing left.

That should be normal. Ideally your system should have 0 bytes of truly free,
unused physical memory.

All of your "free" memory should be used as cache, which can be quickly
reallocated whenever an application needs memory. The cache in Linux is highly
dynamic and this can happen on-demand with very little overhead.

So keep in mind, cache ram is not memory that's permanently tied up in that
task. It's simply "on loan" to the cache pool until it is needed elsewhere.

 The end result has been the system to periodically
> hanging, which forces me to reboot the server. 

That should not be related. Since the cache ram will be reallocated as soon as
it's needed, you're not really out of ram.

Fundamentally your "free to be used by applications when needed" memory is
free+cache, not just free.

Free simply means "not used for anything at all" or "wasted due to lack of
kernel efficiency".

> 
> Does anyone know of any memory leak issues with Fedora Core 5 or the
> applications  that I mentioned above? Thanks. 
> 

No, it's normal behavior of the linux kernel. It's just trying to make the most
of the available physical memory by temporarily turning the otherwise idle
memory into disk cache.

For what it's worth, modern MS Windows does the same thing, but less
aggressively, because there's more overhead associated with reducing the cache size.



More information about the MailScanner mailing list