nsca PROCESS_HOST_CHECK_RESULT problem

Bratislav Stojkovic miskobs at yahoo.com
Tue Apr 3 15:07:53 CEST 2007


Hi.

I have problem regarding nsca and PROCESS_HOST_CHECK_RESULT. 
Actually I configure nsca using standard procedure and everything works fine except PROCESS_HOST_CHECK_RESULT.
(nagios 2.8, nsca 2.71)


- nagios.cfg

ocsp_command=send_service_check
ochp_command=send_host_check


 - cat /usr/lib/nagios/plugins/send_host_check
-------
#!/bin/sh
# Arguments:
# $1 = Hostname of the host (using the $HOSTNAME$ macro)
# $2 = Host Status ID of the host (using the $HOSTSTATUSID$ macro)
# $3 = Output of the host check (using the $HOSTOUTPUT$ macro)
/bin/echo "$1","$2","$3" | /usr/bin/send_nsca -H IP_ADDRESS -c /etc/nagios/send_nsca.cfg -d ","
-------------

- cat /usr/lib/nagios/plugins/send_service_check
--------------
#!/bin/sh
# Arguments:
# $1 = Hostname of the host (using the $HOSTNAME$ macro)
# $2 = Service Description of the service (using the $SERVICEDESC$ macro)
# $3 = Service Status ID of the service (using the $SERVICESTATUSID$ macro)
# $4 = Output of the service check (using the $SERVICEOUTPUT$ macro)
/bin/echo "$1","$2","$3","$4" | /usr/bin/send_nsca -H IP_ADDRESS -c /etc/nagios/send_nsca.cfg  -d ","
------------

- misccommands.cfg:
---------------
define command{
        command_name send_host_check
        command_line /usr/lib/nagios/plugins/send_host_check $HOSTNAME$ $HOSTSTATEID$ "$HOSTOUTPUT$"
}

define command{
        command_name send_service_check
        command_line /usr/lib/nagios/plugins/send_service_check $HOSTNAME$ '$SERVICEDESC$' $SERVICESTATEID$ '$SERVICEOUTPUT$'
}
-------------
If I simulate host down I  got HOST_CHECK from nagios.log on remote host:

EXTERNAL COMMAND: PROCESS_HOST_CHECK_RESULT;server1;1;PING CRITICAL - Packet loss = 100%

but regularly,
it  is triggered like it is service check, and PROCESS_HOST_CHECK_RESULT is not performed at all.

[1175605177] EXTERNAL COMMAND: PROCESS_SERVICE_CHECK_RESULT;server1;0;0; RTA = 0.18 ms
[1175605177] Warning:  Passive check result was received for service '0' on host 'server1', but the service could not be found!


Bratislav.

  ...gios-users at lists.sourceforge.n





 
____________________________________________________________________________________
Looking for earth-friendly autos? 
Browse Top Cars by "Green Rating" at Yahoo! Autos' Green Center.
http://autos.yahoo.com/green_center/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20070403/8dcbe82f/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null


More information about the Users mailing list