[Baypiggies] find memory leaks in running program

Aahz aahz at pythoncraft.com
Tue Dec 7 23:13:28 CET 2010

On Tue, Dec 07, 2010, Marco Hornung wrote:
> I have to debug a multithreaded server, which is written in the
> twisted-framework. One of the processes has some sort of memory leak -
> After one of our jobs is finished the main process has still over 59%
> of the entire memory allocated. I will probably have to recreate our
> scenario and equip our server with some memory sensors - but it takes
> 12h to reproduce the scenario and I will have to change the source
> code(at least I do not know of other options).

This may not be a memory leak; Python often does not return memory to the
OS, and even when memory is returned, the OS may leave it allocated to
the application.  First question is whether the memory usage you see is
resident.  Next question is whether you leak additional memory if you run
the process again.
Aahz (aahz at pythoncraft.com)           <*>         http://www.pythoncraft.com/

"Think of it as evolution in action."  --Tony Rand

More information about the Baypiggies mailing list