[HPADM] SUMMARY: determining CPU time of a running process

From: gary.paveza@AIG.COM
Date: Thu Mar 25 2004 - 19:22:24 EST


As pointed out by quite a few people, ps displays this value in the TIME
column. I must have read the man pages several times looking for a column
like this, but for some reasons, never saw it. Thanks for everyone for
helping.

-----Original Message-----
From: Paveza, Gary [mailto:gary.paveza@AIG.COM]
Sent: Thursday, March 25, 2004 9:25 AM
To: 'HP9000 Admin'
Subject: [HPADM] determining CPU time of a running process

Does anyone know of a way to query a process and determine how much CPU time
is has used? Glance shows it very well, however, I have a requirement that
I be able to run a script and identify likely run-away processes and send an
email alert on them.

For example (from glance):

----------------------------------------------------------------------------

----
                                  PROCESS LIST                      Users=
47
                              User      CPU Util     Cum     Disk
Thd
Process Name   PID   PPID Pri Name   (  800% max)    CPU   IO Rate    RSS
Cnt
----------------------------------------------------------------------------
----
rts32_t      17807      1 241 plpcd5    102/99.8 82170.1  0.0/ 0.0   6.1mb
2
rts32_t        694      1 241 plpcd5    101/99.8 89529.5  0.0/ 0.0   5.7mb
2
I will be keying off two fields (PPID being 1) or Cum CPU being greater than
a certain amount (like 3000 seconds).
---------------------------------------------------------
Gary Paveza, Jr.
Senior Systems Administrator -CSA
(302) 252-4831 - phone
(302) 588-6368 - cell
--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact
majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner:
owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse
only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse &
search)
--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


AdmID:68EC731DD84E597C223D7B1C4A1BAEF4

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)



This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:39 EDT