I am using Nagios to monitor Windows hosts. I am using Nagios 3.5 running on a Centos 7 server. The following packages have been installed from the official repositories and from the EPEL repository:


So far I am using the 'check_nt' method to run some basic checks on the windows hosts. This is working fine.

Now I want to use the check_hwinfo plugin to gather information about the hosts in a single place. This plugin requires NRPE in order to run.

In the 'commands.cfg' file I have added:

define command{
    command_name    check_hwinfo
    command_line    $USER1$/check_nrpe_hwinfo $HOSTNAME$ $HOSTADDRESS$

In the 'nrpe.cfg' I have added:

command[check_hwinfo]=/usr/bin/sudo /usr/lib64/nagios/plugins/check_hwinfo.pl
command[check_hwinfo_csv]=/usr/bin/sudo /usr/lib64/nagios/plugins/check_hwinfo.pl -t csv

command[check_hwinfo]=c:\windows\system32\cscript.exe //NoLogo //T:10 "C:check_hwinfo\check_hwinfo.wsf"
command[check_hwinfo_csv]=c:\windows\system32\cscript.exe //NoLogo //T:10 "C:\check_hwinfo\check_hwinfo.wsf" /sep:csv

I have copied the 'check_hwinfo.pl' script in the '/usr/lib64/nagios/plugins' folder and made it executable, with identical permissions with the other scripts in the folder.

I have added these lines to '/etc/sudoers' in order to execute without password:

Defaults:nagios      !requiretty
nagios ALL=NOPASSWD: /usr/lib/nagios/plugins/check_hwinfo.pl "", /usr/lib/nagios/plugins/check_hwinfo.pl -t csv

On the client side, I am running NSClient++ on the Windows hosts I am monitoring. For check_hwinfo I made the folder 'C:\check_hwinfo' and put inside the 'check_hwinfo.wsf' file needed for running the test on Windows.

This is my nsclient.ini and this is my nsclient-full.ini files.

While all the other checks (via check_nt) are working fine, check_hwinfo refuses to work no matter what I try. The service status in the Nagios page is 'WARNING' and the error message is 'No handler for command: check_hwinfo_csv'.

Does anybody have experience with check_hwinfo? Can you please point me in the right direction?


When trying to run check_nrpe manualy I get this:

./check_nrpe -H -c CheckDisk
No handler for command: checkdisk

It is the same as the error message I get at the GUI from the check_hwinfo plugin

No handler for command: check_hwinfo_csv 


In the Windows client, in the nsclient-full.ini file I have the following definitions:

check_hwinfo_csv=C:\check_hwinfo\check_hwinfo.wsf -t csv
  • Can NRPE sudo without password? Oct 14, 2014 at 11:07
  • @ChristopherPerrin I have actually taken care of that in the /etc/sudoers file. See the update.
    – dlyk1988
    Oct 14, 2014 at 11:16
  • Show us the output of a manual test, running check_nrpe manually.
    – Keith
    Oct 14, 2014 at 14:43
  • Wait... you know you have to define the check_hwinfo commands on the Windows side, right? If you're asking about a Windows box, nothing starting with "/usr/lib64" is relevant at all. Also, there is no Nagios 6.5
    – Keith
    Oct 14, 2014 at 14:43
  • @Keith Fixed the typo. It is now 'Nagios 3.5'. Also, there is no mention of '/usr/lib64...' on my windows hosts. Tomorrow I will run the manual check and report back here.
    – dlyk1988
    Oct 14, 2014 at 14:48

1 Answer 1


That error indicates that you don't have the external script handler enabled. Fortunately, nsclient++ has excellent documentation on this subject.

(Looks like they're currently in the process of re-doing the wiki/docs, so you might want to check the old one too if something's missing.)

  • I have enabled external scripts the way it is described in the article.
    – dlyk1988
    Oct 20, 2014 at 6:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .