Check_disk (from nagios-nrpe-server, Ubuntu-Package) not working via check_nrpe (icinga)

Icinga-Version: 2.5.4-1
OS: Debian 8.6
nagios-nrpe-plugin: 2.15-1
Icinga enabled features: checker command compatlog debuglog graphite ido-mysql livestatus mainlog notification statusdata
OS of monitored Host: Ubuntu 20.04.2 LTS
Version of nagios-monitoring-plugins (package nagios-nrpe-server) on monitored host: 4.0.0-2ubuntu1

Hi all,

we are experiencing problems with the monitoring of a “classic” ramdisk with an ext4-filesystem (automatically created and mounted at system boot). We configured the monitoring using check_disk (from the nagios-nrpe-server provided by Ubuntu’s repository).

This monitoring was setup by a colleague who left the company and did not document what he did and nobody has an idea of how everything works together or if our setup maybe is a huge mess and works only by accident. A complete rebuild is already planned by an external consultant. I don’t know much about monitoring, too (except how to add services to be monitored)

We have this command configured as “check_firebird_temp” in nrpe.conf but showing the issue via console should be enough.

When calling the command on the monitored host as the daemon user, check_disk works as expected:

root@dtzsvmerp:/# sudo -u nagios bash -c "/usr/lib/nagios/plugins/check_disk -w 50% -c 10% /dev/ram0"
DISK OK - free space: /tmp/firebird 9311 MB (98% inode=99%);| /tmp/firebird=175MB;5007;9013;0;10015

However, when calling it through check_nrpe on the icinga-server we get the following output:

root@DTZSMONITORING:/etc/icinga2# /usr/lib/nagios/plugins/check_nrpe -H dtzaverp -c check_firebird_temp
DISK CRITICAL - free space: /tmp/firebird 0 MB (0% inode=99%);| /tmp/firebird=0MB;0;0;0;0

We already tried the possible solutions posted elsewhere (add -m to the check-command, monitor the mountpoint instead of the device etc.) but on the icinga-Server we always get this output.

If this problem doesn’t belong into this forum here, then please let me know (and if possible, a suggestion where to tell about our problem).

Thanks in advance,
Ben

Hey,
How is this command defined in nrpe.conf?

It’s defined the same way as I call it via shell (except for sudo):

command[check_firebird_temp]=/usr/lib/nagios/plugins/check_disk -w 50% -c 10% /dev/ram0