Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a working Nagios setup where I e.g. monitor disk usage through the NRPE daemon without parsing arguments through NRPE for security reasons. So I know that NRPE works.

Now I would like to check NFS using the check_mountpoints plugin, but I get

NRPE: Unable to read output 

On Nagios Monitor host I have set

define command {
  command_name check_mountpoints
  command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -p 5666 -c check_mountpoints 

define service {
  use                     generic-service
  name                    check_mountpoints
  service_description     Check_mountpoints for nfs cifs davfs
  check_command           check_nrpe!check_mountpoints
  contact_groups          linux-admins

On the remote host have I set

command[check_mountpoints]=/usr/lib/nagios/plugins/ /nas1/home

To verify that the correct arguments have been given the command outputs this

[root@nas ~]# /usr/lib/nagios/plugins/ /nas1/home
OK: all mounts were found ( /nas1/home)
[root@nas ~]# 

And both Nagios monitor host and remote host have a working NRPE daemon running.


How do I debug something like this?

share|improve this question
Did you try to run the same script with nagios user? I can see that you are running it as root in the working example above. – Khaled May 9 '12 at 9:08
Very nicely spotted. That was the problem. The permissions of were 750, which had to be 755. – Sandra May 9 '12 at 9:13
up vote 2 down vote accepted

From my experience, this error is caused by missing permissions. You tried to execute the nrpe client script as root. Try to execute it as the user the nrpe daemon is running as. This should give you an hint towards the cause. If this does not help, try to run

strace usr/lib/nagios/plugins/ /nas1/home

as the nrpe user.

share|improve this answer
You are a genius! The permissions of had to be changed to 755. Doing that solved the problem =) – Sandra May 9 '12 at 9:11
I'm glad that i can help you. Since the problem is resolved, please accept the answer. – ercpe May 9 '12 at 9:13

I had the same problema, many times it was permission. Setting permission or using sudoers solve it.

Try to login with nrpe/nagios user (su - nrpe) and try to run the command.

Other possibilite is the selinux, try to disable is TO TEST:

echo 0 > /selinux/enforce
share|improve this answer

To fix this issue without making the nagios plugin world-readable and/or world-executable, add the nrpe user to the nagios group.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.