Monitoring via passive checks

Nagwin is capable of processing external commands issued by other applications, allowing to monitor systems via passive checks rather than issuing active checks.


  • Create the bash script below in the bin directory (send_extcmd as example):
# A shell script to submit an external command to Nagwin. 
# Parameters:
# external command and its parameters. Example:
#    PROCESS_HOST_CHECK_RESULT;host1;0;Host appears to be UP

now=`date +%s`
nanos=`date +%N`

/bin/printf "[%lu] $1\n" $now > $commandfile


A full listing of external commands that can be used can be found here.



  • Host A is UP:

send_extcmd "PROCESS_HOST_CHECK_RESULT;hosta;0;Host A is UP"

  • Service A on Host B is working properly:

send_extcmd "PROCESS_SERVICE_CHECK_RESULT;hosta;servicea;0;OK - Service A is working properly."

  • Send a set of of external commands in a file:

send_extcmd "PROCESS_FILE;/tmp/morecommands.cmd;0"