nixCraft Linux Forum

nixCraft

Linux / UNIX Tech Support Forum

Nagios - No output returned from plugin

This is a discussion on Nagios - No output returned from plugin within the Linux software forums, part of the Linux Getting Started category; Hello Friends, By searching a huge information database on the Internet,finally I am asking you to give me solution to ...


Go Back   nixCraft Linux Forum > Linux Getting Started > Linux software

Linux answers from nixCraft.


Linux software General questions and discussion about Redhat/Fedora Core/Cent OS, Debian and Ubuntu Linux related to softwares should go here.

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-07-2009, 12:23 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Smile Nagios - No output returned from plugin

Hello Friends,

By searching a huge information database on the Internet,finally I am asking you to give me solution to configure NRPE for AIX. Please check below steps for detailed information.

1) Configured Nagios Server 3.0.6 on CentOS 5.2 & it is working fine with normal commands. I am getting localhost "Disk Usage, Memory, Swap Space etc..."

2) I have 3 nos.of AIX 5.3 OS & all AIX Servers are connected with my CentOS 5.2 in a same LAN Switch. I can ping & ssh locally & i have configured check_ssh , check_ftp , check_http services on my CentOS to monitor AIX Servers.

3) Now, I though to install NRPE on AIX 5.3,so that I can get better AIX Server Output like ... Disk Usage,Swap Usage,CPU Load, Online Users.

4) For that,i have downloaded AIX compiled patch from below listed URL
http://www.monitoringexchange.org/cgi-b ... 9.html;d=1

I have copied all tar files,which i download onto AIX Servers & did all things as mentioned in "howto.txt" file.

5) All plugins on AIX is working locally.Check below result.

/usr/local/nagios/libexec/check_swap -w 30% -c 10%
SWAP OK - 100% free (41057 MB out of 41472 MB) |swap=41057MB;12441;4147;0;41472


Now, from Nagios Server Side, executing the same command,giving me an error.
./check_nrpe -n -H 10.100.19.86 -c check_swap -t 30
NRPE: Command 'check_swap' not defined


6) On the Nagios Web Interface,i am getting error of :- No output returned from plugin
Kindly check attached snap1.jpg

7) I have configured nagios server 3.0.2 & NRPE version 2.12 on AIX,which is tested as per the "nagios exchange" community. Then, why i am getting this error?

Some Command output of AIX PC.(Which is NRPE installed)
---
ps -ef | grep nrpe
nagios 164070 1 0 17:23:41 - 0:01 /usr/local/nagios/nrpe -c /usr/local/nagios/nrpe.cfg -d
---
Some Important Command Outputs :-

If I type below command from centos nagios server to aix nrpe client, i am getting below message.
----------------------------
/usr/local/nagios/libexec/check_nrpe -H <AIX PC IP> -c check_load -t 30
CHECK_NRPE: Error - Could not complete SSL handshake.
----------------------------
/usr/local/nagios/libexec/check_nrpe -H <AIX PC IP> -c check_load -t 30 -n
NRPE: Command 'check_load' not defined
----------------------------
/usr/local/nagios/libexec/check_nrpe -n -H localhost
CHECK_NRPE: Error receiving data from daemon.
----------------------------
./check_nrpe -H localhost
NRPE v2.12
----------------------------
[b]telnet <aix pc> 5666
Trying 10.100.19.86...
Connected to gjvatwb1 (10.100.19.86).
Escape character is '^]'.

It means, AIX NRPE is working fine???
----------------------------
netstat -at | grep nrpe
tcp 0 0 *:nrpe *:* LISTEN
----------------------------
telnet <centos pc> 5666
Trying 127.0.0.1
Connected to localhost (127.0.0.1)
Escape character is '^]'.
----------------------------
nagios server's command.cfg file details.


define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -n -H $HOSTADDRESS$ -w $ARG1$
}

without -n , my nagios server can't fetch data from aix pc.
----------------------------
nagios server's switch.cfg file details.

define service{
use generic-service ; Inherit values from a template
host_name gjvatwb1 ; The name of the host the service is associated with
service_description Swap Space ; The service description
check_command check_nrpe!check_swap ; The command used to monitor the service
normal_check_interval 5 ; Check the service every 5 minutes under normal conditions
retry_check_interval 1 ; Re-check the service every minute until its final/hard state is determined
}

Same service configuration for check_disk , check_users & check_load , !!!!!!! But, all services are giving same error.
I have configured "nrpe 2.12.tar.gz" plugin on centos as per the documentation provided in the nagios.pdf format.


Kindly suggest me what is the solution for this error? I tried my best to find out hundreds of links on the internet,but got nothing.



Advanced Thanks,
Nishith Vyas
Attached Images
File Type: jpg snap1.jpg (98.8 KB, 3 views)

Last edited by nixcraft; 04-07-2009 at 11:26 AM.
Reply With Quote
  #2 (permalink)  
Old 04-07-2009, 03:07 AM
jaysunn's Avatar
Powered By Linux
User
 
Join Date: Apr 2009
Location: 41.332032,-73.089775
OS: RHEL - OSX
Scripting language: BASH - Learning Ruby
Posts: 604
Thanks: 61
Thanked 80 Times in 72 Posts
Rep Power: 10
jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold
Default

Hello this error usually occurs for me when I do not define the check_swap piece in the /etc/nagios/nrpe.cfg, or when I have a firewall blocking nrpe requests.

Please check that the nrpe configuration file has the check_swap portion set correctly.

Here is a snippet of one of my RHEL nagios clients:

Code:
#command[check_users]=/usr/local/nagios/check_users -w 5 -c 10
command[check_load]=/usr/local/nagios/check_load -w 2.4,2.2,2.2 -c 3.0,2.6,2.6
command[check_zombie_procs]=/usr/local/nagios/check_procs -w 5 -c 10 -s Z
command[check_total_procs]=/usr/local/nagios/check_procs -w 350 -c 400
command[check_usr_space]=/usr/local/nagios/check_disk -w 30% -c 20% -p /usr
command[check_slash_space]=/usr/local/nagios/check_disk -w 10% -c 5% -p /
command[check_home_space]=/usr/local/nagios/check_disk -w 50% -c 30% -p /home
command[check_var_space]=/usr/local/nagios/check_disk -w 50% -c 30% -p /var
command[check_export_space]=/usr/local/nagios/check_disk -w 50% -c 30% -p /export/home
#command[check_nasnyc1_space]=/usr/local/nagios/check_disk -w 50% -c 30% -p /mnt/nasnyc2
command[check_swap]=/usr/local/nagios/check_swap -w 95% -c 90%
Also we use a great open source configuration tool for Nagios called fruity. Have a look:

http://sourceforge.net/projects/freshmeat_fruitynagios/


Not sure if this is any assistance.

Jaysunn
__________________
Have a look at what I have been working on
http://www.shellasaurus.com

Last edited by jaysunn; 04-07-2009 at 03:14 AM.
Reply With Quote
  #3 (permalink)  
Old 04-07-2009, 02:24 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Cool nrpe client working on localhost,but not for remote server.

Dear Friend,

My problem is I am getting response from my client server. I have 2 linux machines,configured with nagios,nrpe & nrpe plugin. I did all as per the nagios offficial documentation.

Now, Please note that CentOS is my nagios monitoring server & Fedora is my nrpe client. i need to get all data from fedora linux through NRPE.

here is the output.

CentOS Output
:-

/usr/local/nagios/libexec/check_load -w 1,2,3 -c 2,3,4
OK - load average: 0.09, 0.16, 0.23|load1=0.090;1.000;2.000;0; load5=0.160;2.000;3.000;0; load15=0.230;3.000;4.000;0;

grep check_load /usr/local/nagios/etc/nrpe.cfg
command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,25,20
#command[check_load]=/usr/local/nagios/libexec/check_load -w $ARG1$ -c $ARG2$


/bin/su - nagios -c "/usr/local/nagios/libexec/check_load -w 1,2,3 -c 2,3,4"
OK - load average: 0.04, 0.14, 0.22|load1=0.040;1.000;2.000;0; load5=0.140;2.000;3.000;0; load15=0.220;3.000;4.000;0;


telnet localhost 5666
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.


netstat -at | grep nrpe
tcp 0 0 *:nrpe *:* LISTEN


But, no output i am getting by typing
netstat -at | grep 5666

Now,Fedora NRPE Client PC Output shown below.

/usr/local/nagios/libexec/check_load -w 1,2,3 -c 2,3,4
OK - load average: 0.01, 0.02, 0.00|load1=0.010;1.000;2.000;0; load5=0.020;2.000;3.000;0; load15=0.000;3.000;4.000;0;

grep check_load /usr/local/nagios/etc/nrpe.cfg
command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,25,20
#command[check_load]=/usr/local/nagios/libexec/check_load -w $ARG1$ -c $ARG2$

/bin/su - nagios -c "/usr/local/nagios/libexec/check_load -w 1,2,3 -c 2,3,4"
OK - load average: 0.00, 0.02, 0.00|load1=0.000;1.000;2.000;0; load5=0.020;2.000;3.000;0; load15=0.000;3.000;4.000;0;

But,

telnet localhost 5666 is not working.See Below.
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.

Telnet from fedora client to centos pc,working fine. See Below
telnet <centos ip> 5666
Trying 203.77.197.118...
Connected to 203.77.197.118.
Escape character is '^]'.

What else i need to check?

????????????????????
Reply With Quote
  #4 (permalink)  
Old 05-07-2009, 06:33 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Thumbs down Any Luck.!!!!!!!!!!!!!

Anyone is having proper answer of my query? I am still in problem......
Reply With Quote
  #5 (permalink)  
Old 05-07-2009, 07:14 PM
jaysunn's Avatar
Powered By Linux
User
 
Join Date: Apr 2009
Location: 41.332032,-73.089775
OS: RHEL - OSX
Scripting language: BASH - Learning Ruby
Posts: 604
Thanks: 61
Thanked 80 Times in 72 Posts
Rep Power: 10
jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold
Default

Please give this a try, Enable the debug option in the nrpe.cfg file:

Code:
# DEBUGGING OPTION
# This option determines whether or not debugging messages are logged to the
# syslog facility.
# Values: 0=debugging off, 1=debugging on

debug=1
This may gather some data in regards to solving your problem. I run nagios on rhel servers. AIX is really not my forte. However we may get some answers in regards to the syslog. Also is /var/log/messages giving any clues?

Jaysunn
__________________
Have a look at what I have been working on
http://www.shellasaurus.com
Reply With Quote
  #6 (permalink)  
Old 05-07-2009, 07:20 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Smile I will provide you the output very soon.

Dear Friend,

Kindly wait for some moments. I will provide you "syslog" messages alone with "debug" info from NAGIOS.

Kindly Be In Touch.

Thanks.
Nishith
Reply With Quote
  #7 (permalink)  
Old 05-07-2009, 07:27 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Exclamation Output of "debug"

Here is the output log of "syslog" service.

Jul 5 19:29:53 firewall nagios: SERVICE NOTIFICATION: nagiosadmin;gjvatwb1;CPU Load;UNKNOWN;notify-service-by-email;(No output returned from plugin)

Here is the output log of "nagios.log" service.

[1246802455] Warning: Contact 'nagiosadmin' host notification command '/usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: PROBLEM\nHost: LinuxGuru-119\nState: DOWN\nAddress: 10.100.19.86\nInfo: (Host Check Timed Out)\n\nDate/Time: Sun Jul 5 19:30:24 IST 2009\n" | /bin/mail -s "** PROBLEM Host Alert: LinuxGuru-119 is DOWN **" nishith@localhost.net' timed out after 30 seconds
[1246802455] HOST NOTIFICATION: nagiosadmin;gjvatdb3;DOWN;notify-host-by-email;(Host Check Timed Out)

What to do now?
Reply With Quote
  #8 (permalink)  
Old 05-07-2009, 07:31 PM
Member
User
 
Join Date: Jul 2008
OS: Fedora
Posts: 41
Thanks: 1
Thanked 1 Time in 1 Post
Rep Power: 0
nishith is on a distinguished road
Default Web Based Error.

Status InformationNo output returned from plugin)
NRPE Plugin for Nagios
Copyright (c) 1999-2008 Ethan Galstad (nagios@nagios.org)
Version: 2.12
Last Modified: 03-10-2008
License: GPL v2 with exemptions (-l for more info)
SSL/TLS Available: Anonymous DH Mode, OpenSSL 0.9.6 or higher required

Usage: check_nrpe -H <host> [-n] [-u] [-p <port>] [-t <timeout>] [-c <command>] [-a <arglist...>]

Options:
-n = Do no use SSL
-u = Make socket timeouts return an UNKNOWN state instead of CRITICAL
<host> = The address of the host running the NRPE daemon
[port] = The port on which the daemon is running (default=5666)
[timeout] = Number of seconds before connection times out (default=10)
[command] = The name of the command that the remote daemon should run
[arglist] = Optional arguments that should be passed to the command. Multiple
arguments should be separated by a space. If provided, this must be
the last option supplied on the command line.

Note:
This plugin requires that you have the NRPE daemon running on the remote host.
You must also have configured the daemon to associate a specific plugin command
with the [command] option you are specifying here. Upon receipt of the
[command] argument, the NRPE daemon will run the appropriate plugin command and
send the plugin output and return code back to *this* plugin. This allows you
to execute plugins on remote hosts and 'fake' the results to make Nagios think
the plugin is being run locally.

Performance Data:
Current Attempt:3/3 (HARD state) Last Check Time:07-05-2009 19:29:46 Check Type:ACTIVE Check Latency / Duration:0.097 / 0.034 seconds Next Scheduled Check: 07-05-2009 19:34:46 Last State Change:07-02-2009 18:13:11 Last Notification:07-05-2009 19:29:53 (notification 70) Is This Service Flapping? NO
(0.00% state change) In Scheduled Downtime? NO
Last Update:07-05-2009 19:34:17 ( 0d 0h 0m 2s ago)
Reply With Quote
  #9 (permalink)  
Old 05-07-2009, 07:47 PM
jaysunn's Avatar
Powered By Linux
User
 
Join Date: Apr 2009
Location: 41.332032,-73.089775
OS: RHEL - OSX
Scripting language: BASH - Learning Ruby
Posts: 604
Thanks: 61
Thanked 80 Times in 72 Posts
Rep Power: 10
jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold jaysunn is a splendid one to behold
Default

Please try using the -n option. I have been reading about this flag. This is used if the ssl option was not compiled into the nagios install.
Code:
/usr/local/nagios/libexec/check_nrpe -n -H localhost -c check_users

/usr/local/nagios/nrpe -n -c nrpe.cfg -d (if running in daemon mode).
See if that fixes the:

Code:
CHECK_NRPE: Error - Could not complete SSL handshake.
I will continue to research your issue. Also double check the iptables. You need to be sure that telnet localhost 5666 gets working. On the fedora machine temporarily stop iptables and test the telnet.

Code:
/etc/init.d/iptables stop
Jaysunn
__________________
Have a look at what I have been working on
http://www.shellasaurus.com
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
How to create QEMU plugin for Mozilla Firefox? Lubes Coding in General 0 05-11-2008 12:31 AM
Nagios on tomcat? Vince-0 Linux software 0 22-04-2008 01:30 PM
Monitoring FreeBSD Jails for Updates with Nagios? igno2k All about FreeBSD/OpenBSD/NetBSD 0 12-11-2007 08:05 PM
About iptables output satimis Networking, Firewalls and Security 0 30-09-2007 08:30 AM
How to redirect Output puppen Shell scripting 15 06-12-2006 08:44 PM


All times are GMT +5.5. The time now is 06:33 AM.


Powered by vBulletin® Version 3.8.5 - Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
©2005-2010 nixCraft. All rights reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38