I've another problem about my configuration.
I want to supervise a windows task "prix.job" and to receive notifications if the job is disabled or if the task is not working more than 30 min.
In windows.cfg :
Code: Select all
define service {
use generic-service
host-name workflow
notification_interval 15
service_description prix.job more than 30 min
check_command CheckTaskSched!prix.job!30
}Code: Select all
define command {
command_name CheckTaskSched
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckTaskSched -a "filter=title = '$ARG1$' AND status = 'enabled' AND most_recent_run_time < -$ARG2$" "syntax=%title% (%most_recent_run_time%)" MaxWarn=1
}I've tested to write status= 'running' or status= 'disabled', but this is the same problem.
In the command line, if i test :
Code: Select all
.\check_nrpe -H 132.147.160.138 -c CheckTaskSched "filter=title=prix.job"Code: Select all
OK : All tasks are OK {...} 'prix.job_exit_code'=0;0;0