3

Possible Duplicate:
How to check how a long a program has been running?

I am interested in doing this purely using bash.

4

ps can fit your needs:

ps -eo pid,command,etime

To get information for a specific process:

ps -o command,etime -p PID
| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.