Monitoring Windows using nsclient++ without icinga2 client

Hi People, i´m triing to monitoring several windows host and i need use nsclient++ only.

in my icinga server i tried to check one test host using /usr/lib/nagios/plugins/check_nt -p 12489 -s "password" -H "test host ip" r -v CPULOAD -l 5,80,90 -t 60

the result is CRITICAL - Socket timeout after 60 seconds

all another check_nt commands fails whit the same error

In the client side, i have de nsclient.ini configured:

  • allowed hosts (localhost and icingaserver)
  • password
  • checkdisk
  • checksystem
  • webserver

all tests on the local web server are funcional.

don’t know how to continue to solve the problem

Icinga version: r2.10.5-1 runing on Ubuntu 18.08

Is the required Firewall Port allowed which is mamdatory for nsclient… I think tcp/5665 or something like this.

Tbh I have never used the check_nt part of NSClient. I only ever used NRPE.

Check the nsclient.ini for the configured timeouts.
Are the correct modules enabled? Maybe try running nscp settings --generate --add-defaults --load-all from the Windows cmd (where the nscp.exe is located), to load all modules and the whole default config. With nscp settings --generate --remove-defaults you can remove the defaults again
Have you checked the nsclient.log on the windows machine?

As for the firewall:

  • Windows:
    – Normally when installing the nsclient, the windows firewall is configured.
  • other firewalls:
    – as @MoeJoe said you will have to check if the required ports are open. check_nt uses 12489 as default, NRPE uses tcp/5666

This is the Icinga 2 communication port :wink:

2 Likes

Thanks for the help. Is a problem with these client in particular, the firewall is off and the client are LISTEN con 5666 port and 12489 port.
the commands nc -zv “ip” 12489 and 5666 port from the server are ok.

We Say 'Cosa de mandinga’ for these cases

Grettings from Argentina