Operating System - HP-UX
1827459 Members
4674 Online
109965 Solutions
New Discussion

Gather resource utilization by a process

 
SOLVED
Go to solution
Tony Contratto
Respected Contributor

Gather resource utilization by a process

I have been asked the following question by the application support group for one of our servers:

"Would you know a UNIX command or series of command that would provide the following information about a particular process: stack size, heap size, total size, number of threads, number of open files, number of open sockets, and any other systems resources that a process might have tied up (pretty vague I know)?"

The system is a N4000 running HP-UX 11.00. Any ideas on what would be the best/easiest way for the application group to get this information about the application processes?

Thanks in advance...
Tony
got root?
7 REPLIES 7
Ken Hubnik_2
Honored Contributor

Re: Gather resource utilization by a process

Use glance. It will prompt you for the process number and show you all the resources for that process.
Helen French
Honored Contributor

Re: Gather resource utilization by a process

The best option would be using GlancePlus utility. This is a priced product from HP using as a Performance diagnostics tool. If needed, you can use the free trial copy too.

With this tool, you will be able to narrow down the resource usages, processes running, open files and a lot more!
Life is a promise, fulfill it!
Tony Contratto
Respected Contributor

Re: Gather resource utilization by a process

I have looked at the man page for glance and it has some information about using the Advisor mode to write the gathered information to a log file at a specified interval. The man page doesn't have much detail about how you would set it up to do this. Any suggestions about where I can find more information about it.

We are having a problem with the application and the app. group wants to be able to go back and analyze the gathered information about the processes during the timeframe when it is "broken."

Thanks,
Tony
got root?
Ken Hubnik_2
Honored Contributor

Re: Gather resource utilization by a process

We also gather the date with measureware and then use Perfview to go back and look at the historical measureware data.
Sridhar Bhaskarla
Honored Contributor
Solution

Re: Gather resource utilization by a process

Hi Tony,

Look at /var/opt/perf/parm file. There are some examples of how to group processes together either by the "user" or by "process". They are called applications. Once you setup the applications, you can gather stats about the applications using "extract" utility. Look at /var/opt/perf/reptall and search for "APP". That will list out all the metrics that you can gather information on.

More information is there under /opt/perf/paperdocs directory.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Steven E. Protter
Exalted Contributor

Re: Gather resource utilization by a process

Attached is a general set of data collection scripts that could easily be adapted to your purpose.

They are production.

P
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
Gavin Clarke
Trusted Contributor

Re: Gather resource utilization by a process

Thanks for those scripts, I tend to watch vmstat as most of the time I worry about memory.

These will be very helpful I think.
I use glance too it has lots of helpful bars showing use of all sorts of resources. You can get down to files and processes although I don't tend to go that deep.

Er where does perfview fit into this (is it the logging bit of glance?)