Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

process and function time

Status
Not open for further replies.

emilio500

Programmer
Oct 15, 2000
9
0
0
UY
How can I get statistics about how long a process was running, and how long a procedure/function was running?

Thank you so much
 
I don't know about a function, unless the function is doing something to time itself.... but, if you are on a UNIX box, you can get information about a process using 'ps'.

If you know the processID of the process your interested in....

ps -fp [processID]

If you don't know the processID, this will give a list of the processes returned by ps that contain the name of the process (program).....

ps -ef |grep nameOfProgram

note also, that if you are looking for the process for the program you are running, $$ contains the processID.

'hope this helps....




keep the rudder amid ship and beware the odd typo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top