Page 1 of 1

Check procs does not find a process

Posted: Wed May 18, 2022 4:41 am
by Nalagios
Hello,

I am trying to use check procs to monitor this processes (proc-runner, proc-runner1-2, proc-runner1-3):

Code: Select all

user   312423  0.0  0.0  12724  2516 ?        Ss   Apr19   0:00 /bin/bash /opt/proc-runner/runsvc.sh
user   358742  0.0  0.0  12724  2420 ?        Ss   Apr26   0:00 /bin/bash /opt/proc-runner1-2/runsvc.sh
user  358941  0.0  0.0  12724  2676 ?        Ss   Apr26   0:00 /bin/bash /opt/proc-runner1-3/runsvc.sh
user   825425  0.0  1.7 3580004 141572 ?      Sl   May05   2:04 /opt/proc-runner1-2/bin/Runner.Listener run --startuptype service
But when I try to run the check:

Code: Select all

/usr/lib64/nagios/plugins/check_procs -C \/opt\/proc-runner1-2\/bin\/Runner.Listener -c 1:1 
PROCS CRITICAL: 0 processes with command name '/opt/proc-runner1-2/bin/Runner.Listener' | procs=0;;1:1;0;
I tried escaping characters, just putting /opt/proc-runner1-2/runsvc.sh...

The check is working because I tried just for the "sshd" process and it succeed.

I also tried by using different users, root, nrpe... etc

Re: Check procs does not find a process

Posted: Wed May 18, 2022 4:53 am
by Nalagios
When I do this:

Code: Select all

/usr/lib64/nagios/plugins/check_procs -C Runner.Listener -c 3:3
It works... But the problem is that I would like to do it process by process... Not for the three at the same time.

Re: Check procs does not find a process

Posted: Wed May 18, 2022 5:32 am
by Nalagios
Solved:

I used the "-a" option that allows me to find a string instead of the process.