I have no idea how/if you can do it within your program itself but,
you could turn on "BSD Process Accounting" in your kernel and
use the "psacct package" aka "GNU accounting utilities" to
monitor it.
http://www.bsdtoday.com/2001/January/Features385.html
On Sat, 24 Mar 2001, Jerry Hong wrote:
> Hi,
> Does anybody know how to get process info such as
> (user time, system time, CPU usage, Page faults) in C
> programm? I know in general ioctl(fd, PRSINFO, &..)
> would work, but it doesn't work for Linux.
> Any comments will be welcome.
> Thanks.
>
> Jerry
--
Dan Cyr - Stratabase Network/Systems Administrator
101-34595 3rd Avenue Abbotsford BC, V2S 8B7
Phone: 604-504-5811 ex. 25 Fax: 604-504-5810
Email [EMAIL PROTECTED] Web http://www.stratabase.com
"If you don't want your mistakes pointed out, stop making them."
- ME
_______________________________________________
Redhat-devel-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-devel-list