Page 1 of 1

how to monitor a process that shouldn't be running ?

Posted: Wed Jan 21, 2015 7:40 am
by nagmoto
Hi

check_proc doesn't alert if a process shouldn't running.
Is there other plugin can do this kind of checking ?
Ex, a host has telnet or ftp server daemon running should trigger an alert.


Thanks

Re: how to monitor a process that shouldn't be running ?

Posted: Wed Jan 21, 2015 10:17 am
by slansing
You could actually do this, just set your critical value to >=1 like so:

Code: Select all

/path/to/your/check_procs -c 1 -C nagios

Return: PROCS CRITICAL: 6 processes with command name 'nagios' | procs=6;20;1;0;
There are some fancier things you can do, to get the full usage, check out:

Code: Select all

/path/to/your/check_procs -h

Re: how to monitor a process that shouldn't be running ?

Posted: Wed Jan 21, 2015 12:47 pm
by nagmoto
Thanks for the answer on checking the ftp or sshd process using check_proc command.

Can I also do the ftp/ssh port scanning from Nagios server side ?

Re: how to monitor a process that shouldn't be running ?

Posted: Wed Jan 21, 2015 12:51 pm
by tmcdonald
In regards to your first question that slansing answered, you can also use the negate plugin in similar situations where the threshold might not be a viable option:

http://assets.nagios.com/downloads/nagi ... ios-XI.pdf

The doc mentions XI but works for Core as well.

As for the port scanning, that is available in XI using the Autodiscover Wizard, which uses nmap in the backend.