Operating System - HP-UX
1748285 Members
4051 Online
108761 Solutions
New Discussion

Re: How to determine if a process leaks memory?

 
Sanjaya2005
Frequent Visitor

How to determine if a process leaks memory?

Hi,

 

We usually monitors VSize of a process over a period of time while doing similar/repeated operations. If VSize remains constant, then we conclude that the process does not leaks memory. If we observe continuous growth of VSize, then we suspect that the process is leaking memory. Is my understanding correct ? We are using HPUX Itanium 11.31.

 

Thanks and Regards

Sanjaya

2 REPLIES 2
Bill Hassell
Honored Contributor

Re: How to determine if a process leaks memory?

'Leaking memory' is just a simple term for poor programming technique where temporary memory areas are requested but never returned when no longer needed. It is not unusual for a program to grow rapidly at the beginning, but taper off and never change after a long time. It all depends on how the program is supposed to work. if a program starts small and contunues to grow continuously over days or weeks, then a memory leak can be the reason. Ask the programmer. If no programmer, restart the program or ask for a patch to fix the uncontrolled growth.



Bill Hassell, sysadmin
Dennis Handly
Acclaimed Contributor

Re: How to determine if a process leaks memory?

>If we observe continuous growth of VSize, then we suspect that the process is leaking memory.

 

Either you are leaking memory or you have heap fragmentation.  The latter is something a developer would be normally expecting.