Passive service says its ok while its not

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Passive service says its ok while its not

Post by SDohmen »

We use passive services for our central. For one of our latest customers we noticed that everything is reported as ok even though on the remote nagios it says its a warning.

In total i noticed this with 2 services (1 critical and 1 warning). What can be the cause/solution for this problem?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Passive service says its ok while its not

Post by scottwilkerson »

This will depend on the method used to send the passive results, but it sounds like you are sending a 0 for the state when it should be a 1 or 2
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: Passive service says its ok while its not

Post by SDohmen »

Sorry, i forgot to add that information.

We are using NRPE (over ssl) to send all information. The commands for this are the same for all other customers as well and the local machine also seems to send the warning/critical. Is there a way to check what is being recieved on the central end or anything else for that matter?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Passive service says its ok while its not

Post by scottwilkerson »

NRPE isn't a passive check, that would be an active check. Did you mean NRDP? Does the central show the correct time and output for last check? Is there a Check freshness set for these?
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: Passive service says its ok while its not

Post by SDohmen »

I ment NRDP indeed.

The answers to both other questions are yes. The last check time is always correct and the freshness check hasn't kicked in.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Passive service says its ok while its not

Post by scottwilkerson »

And to be clear, are these being sent by another XI server or core?
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: Passive service says its ok while its not

Post by SDohmen »

The remote sites are all core versions. I use templates for all so it would be weird if it works for 1 but not the other.

The central is of course the nagiosxi
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: Passive service says its ok while its not

Post by SDohmen »

I found the solution. It was actually a strange one as well.

For NRDP i use the 2 following lines:

Code: Select all

define command{
        command_name    submit_check_result
        command_line    /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php --url=https://central/nrdp --token=password --host=$HOSTNAME$ --service='$SERVICEDESC$' --state=$SERVICESTATEID$ --output='$SERVICEOUTPUT$ | $SERVICEPERFDATA$ [$SERVICECHECKCOMMAND$]'
}

define command{
        command_name    submit_host_result
        command_line    /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php --url=https://central/nrdp --token=password --host=$HOSTNAME$ --state=$HOSTSTATEID$ --output='$HOSTOUTPUT$ | $HOSTPERFDATA$'
}
Note the different variables that are being used.

The new one is as follows:

Code: Select all

define command{
        command_name    submit_check_result
        command_line    /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php --url=https://central/nrdp --token=password --host='$HOSTNAME$' --service='$SERVICEDESC$' --state='$SERVICESTATEID$' --output='$SERVICEOUTPUT$ | $SERVICEPERFDATA$ [$SERVICECHECKCOMMAND$]'
}

define command{
        command_name    submit_host_result
        command_line    /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php --url=https://central/nrdp --token=password --host='$HOSTNAME$' --state='$HOSTSTATEID$' --output='$HOSTOUTPUT$ | $HOSTPERFDATA$'
}
It seems after i put all the variables between ' ' it works just fine. This is a bit strange since the first 2 lines work fine for all other probes we use. Thanks for helping though.
Locked