Find memory leaks shell script ???

Hi all,

Has anyone out there a shell script to detect memory leaks on unix machines?

And if so what way did they go about it .?

What platform/OS are you asking about?

Mainly solaris and HP ( 64 bit )

Memory leaks where ? In your application or memory leaks in the kernel ? The kernel ones are hard to catch.

As such there is not shell script which detects memory leaks. You would have to constantly monitor the output of pmap -d, ps -elf listing et al. You need to be careful at the numbers you are looking.

Use valgrind, efence, dmalloc among the various tools available. For me, valgrind has been quite helpful.

The memory leaks would be in the applications that are written local .
I want a shell script to detect the memory leaks ... rather than manual using a third party tool .

Has anyone any idea , i was going to use prstat - but thats not effecient ??????