NRPE – How to fix No Output Returned From Plugin

The NRPE now you can execute Nagios plugins remotely on the Linux/Unix remote machine. In addition to this, you can also communicate with a few windows agent addons in order to executive scripts and check metrics on remote Windows machines.

Our technical team support will fix any sort of Nagios queries under our server management plan. You can also take assistance from our technical team support 24/7 for fixing the error or any sort of installation and migration.

NRPE: No Output Returned From Plugin

causes of the error.

The error is due to incorrect permissions

Due to the missing plugin

Mismatch of Arguments between Nagios XI and nrpe.cfg

Resolving the error.

Incorrect permissions

The solution to permissions on the check_nrpe binary on the Nagios XI server:

ls -la /usr/local/nagios/libexec/check_nrpe

The permissions should resemble:

-rwxrwxr-x. 1 nagios nagios 75444 Nov 21 01:38 check_nrpe

If not, change ownership to user/group “nagios” and fix up the permissions:

chown nagios:nagios /usr/local/nagios/libexec/check_nrpe
chmod u+rwx /usr/local/nagios/libexec/check_nrpe
chmod u+rx /usr/local/nagios/libexec/check_nrpe

Missing Plugin

In case of plugin file missing that leads to the error, will experience a secondary configuration issue.

This used to occur when the plugins referenced by command directive in nrpe.cfg is either missing from the libexec folder or an incorrect command directive name.

It won’t define the nrpe.cfg file on the remote host while passing through the NRPE from the Nagios XI server.

To troubleshoot the error you need the name of the command then request the NRPE to execute.

For instance, ensure that the remote host has defined the command nrpe.cfg :

command[check_foo]=/usr/local/nagios/libexec/check_foo.sh $ARG1$

Later, verify if the spelling of check_foo in $ARG1$ matches that of the command directive name command[check_foo].

Try to ensure the plugins execute on the remote host.

For example name of the plugins.

/usr/local/nagios/libexec/check_foo.sh

Executive the following commands on the remote host.

ls -la /usr/local/nagios/libexec/check_foo.sh

If it does not exist, then the output will be 

ls: cannot access /usr/local/nagios/libexec/check_foo.sh: No such file or directory

If this is the problem, we have to copy the plugin to the /usr/local/nagios/libexec/ folder.

Ensure the filename check_foo.sh has the correct file extension.

Mismatch of Arguments between Nagios XI and nrpe.cfg

Usually, a secondary issue is an argument usage mismatch between the remote host’s nrpe.cfg command directive and the arguments passed by Nagios XI through check_nrpe.

Once you pass the arguments its usage should be consistent between the Nagios XI service check the declared arguments in the command directive in the remote host’s nrpe.cfg.

Additionally, check the remote host’s nrpe.cfg for the dont_blame_nrpe directive.

For example, consider this command executed on the Nagios XI server:

/usr/local/nagios/libexec/check_nrpe -H 10.25.13.30 -t 30 -c check_users -a ‘-w 5 -c 10’

To identify the setting NRPE server has defined, we log into the remote host as the root user and execute:

grep -e ^dont /usr/local/nagios/etc/nrpe.cfg

Output 

dont_blame_nrpe=1

Conclusion

In brief, the cause of the error may be due to various reasons, follow the steps to resolve this error. If you need any assistance, consult our technical team support to resolve the error on your behalf.

Liked!! Share the post.

Share on facebook
Share on twitter
Share on linkedin
Share on reddit

FREE SERVER AUDITING

Get Auditing Report of Your Server for FREE!!

GET THIS ISSUE FIXED !!

$30/month

Server Management