CHECK_NRPE: No output returned with check_iptables.sh script
Kaplan, Andrew H.
AHKAPLAN at PARTNERS.ORG
Tue Jan 18 15:21:39 CET 2011
Hi there --
>> When you run it manually - how do you do it ? check_nrpe -H <host> -c
>> check_iptables from the nagios server ? or local on the client ?
I have run the script on the Nagios server, and on the client system. When I ran
the script
on the server, the syntax I used was the following:
/usr/local/nagios/libexec/check_nrpe -H hadron -c check_iptables
The output of that command was: CHECK_NRPE: No output returned from daemon.
I ran the script on the client using the following syntax:
/usr/local/nrpe/libexec/check_iptables.sh
The output of that command was: OK INPUT 20 rules<br>OK BLACKIN 497 rules<br>OK
BLACKOUT 497 rules<br>
When I ran the command on the client, I did so as the root user. The nagios user
account exists on the
client, but as a means of security it is set up with the /sbin/nologin shell. I
confirmed with other
administrators, as well as in practice, this should not intefere with
operations.
>> If you have not put in return codes how do you expect nagios to know
>> what was the exit status of the script ? how will it know if it finished
>> running or failed - those are not covered from NRPE but determined in
>> the plugin.
I looked at the plugin, and I am not sure what the syntax is for entering the
return codes.
-----Original Message-----
From: Assaf Flatto [mailto:nagios at flatto.net]
Sent: Monday, January 17, 2011 4:24 PM
To: Nagios Users List
Subject: Re: [Nagios-users] CHECK_NRPE: No output returned with
check_iptables.sh script
Kaplan, Andrew H. wrote:
> Hi there --
>
> Thanks for your reply. Regarding your questions:
>
>
>>> Have you tried enabling the debugging on the nrpe client and see what
>>> the output is when you manually trigger the check ?
>>>
>
> I have enabled debugging on the client, and there were no error messages
listed
> in /var/log/messages file.
>
>
>>> Have you tried running the check manually as the nagios user ? what
>>> output did you get ?
>>>
>
> I have run the check manually, and the output appears to be correct.
>
>
>>> what are the return codes that you implemented in the iptables test
>>> script , and what output is sent beside the return codes?
>>>
>
> I have not implemented any return codes in the test script.
>
>
>
>
When you run it manually - how do you do it ? check_nrpe -H <host> -c
check_iptables from the nagios server ? or local on the client ?
If you have not put in return codes how do you expect nagios to know
what was the exit status of the script ? how will it know if it finished
running or failed - those are not covered from NRPE but determined in
the plugin.
Assaf
------------------------------------------------------------------------------
Protect Your Site and Customers from Malware Attacks
Learn about various malware tactics and how to avoid them. Understand
malware threats, the impact they can have on your business, and how you
can protect your company and customers by using code signing.
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
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
The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
------------------------------------------------------------------------------
Protect Your Site and Customers from Malware Attacks
Learn about various malware tactics and how to avoid them. Understand
malware threats, the impact they can have on your business, and how you
can protect your company and customers by using code signing.
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
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