1834234 Members
2297 Online
110066 Solutions
New Discussion

Re: how to script

 
hpuxhelp
Regular Advisor

how to script

does any1 in here have any script on how to detect memory leak?

I think we might have that problem

3 REPLIES 3
twang
Honored Contributor

Re: how to script

Measuring Memory Usage with vmstat

vmstat displays a wealth of information; use the -n option to make it more readable on an 80-column display.

The column to watch most closely is po. If it is not zero, the system is paging. If the system is paging consistently, you probably need more RAM.

you can also take a look at output from
# swapinfo -tam

Steven E. Protter
Exalted Contributor

Re: how to script

If the script runs long enough:

You can find it in Glance Plus(paid add in product) and drill into it ans see statistics on memory use.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
steven Burgess_2
Honored Contributor

Re: how to script

Hi

restart the process and watch it's memory usage

UNIX95= ps -e -o ruser,vsz,pid,args|sed '1d'|sort -rnk2 | more

vsz :-
The size in kilobytes (1024 byte units) of the core image of the process.

Check the man page for ps for more options

HTH

Steve


take your time and think things through