[TriLUG] Re: correction: process monitoring

James Manning jmm at sublogic.com
Sat Jan 18 05:09:05 EST 2003


> [Michael Mueller]
> Anybody think of another way to accomplish this?

killall -0 procname and check $?
pidof procname and check $? or check for output

jmm at xanex:/home/jmm> for i in bash xxx; do
> killall -q $i && echo There is a $i process running
> done
There is a bash process running
jmm at xanex:/home/jmm>

-- 
James Manning <http://www.sublogic.com/james/>
GPG Key fingerprint = B913 2FBD 14A9 CE18 B2B7  9C8E A0BF B026 EEBB F6E4



More information about the TriLUG mailing list