You can get underground processes by
ps ux
I am searching a way to find processes to which I have not touched for 30 minutes.
How can you find processes unused for an half hour?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Define "untouched" and "unused". You can find out lots of things using the
fparameter on ps(1) in BSD-like systems, the-oon Solaris and Sys/V-like systems.Update
Responding to the comment:
Well, you can do it. Consider, for example, something that does a periodic ps, and stores the CPU time used along with time. (Actually, you could do this better with a C program calling the appropriate system calls, but that’s really an implementation detail.) Store sample time and PID, and watch for the PID’s CPU time not having changed over the appropriate interval. This could even be implemented with an awk or perl program like
so that every time awk gets a
psoutput, it mangles it, identifies candidates, and sends them out to show throughtail -f.But then you may well have daemon processes that don’t get called often; it’s not clear to me that CPU time alone is a good measure.
That’s the point about defining what you really want to do: there’s probably a way to do it, but I can’t think of a combination of ps flags alone that will do it.