1

Is there a way to get the CPU and memory usage programmatically (C++) of an application on HPUX?

roalz
  • 2,651
  • 3
  • 27
  • 42
LK__
  • 6,165
  • 4
  • 33
  • 51

3 Answers3

1

How to determine CPU and memory consumption from inside a process

Answers are given for Windows and Linux, not HPUX, but the Linux version might lead you in the right direction.

Community
  • 1
  • 1
luke
  • 34,649
  • 7
  • 57
  • 81
0

HP-UX supports getrusage().

Martin v. Löwis
  • 120,633
  • 17
  • 193
  • 234
0

If you need to get the numbers for a different process, use pstat_getproc().

mark4o
  • 55,879
  • 16
  • 84
  • 100