@inform And I assume if you paste this URL into your web browser on the XI server, you'll be able to access the web page as well, right? If the answer to that is yes, i'd recommend adding --ssl flag to your command in Core configuration manager. Just like that:
I have Nagios XI (server) running on Centos 7, and have the NSClient++ (agent) running on Windows Server 2012 R2. Installing the agent was straightforward and I encountered no errors. I put the password in the server's CPU service which I enabled for the windows host. Since I was getting connection refused errors where the server was trying to connect with the agent over port 12489 I looked at the agent. The only port being listened on was 5666. I ran netstat -abno|grep -P '12489|566[67]' in mingw64. I even put these lines in the nsclient.ini file:
[/settings/NSCA/client/targets/default]
; PORT NUMBER - Port to use for check_nt.
port = 12489
and restarted the agent. Still only listening on port 5666. Failing that I went to the server command area (do this by clicking in the top menu Configure -> Core Config manager, then in the sidebar expand Commands and cick the expanded Commands to open them), located check_xi_service_nsclient and changed the port from 12489 to 5666. Next I forced a recheck of the CPU service. The server worked fine and was able to determine the CPU usage. Prior to that I started the agent in test mode:
net stop nscp
nscp test --log trace
To get out of test mode type this: exit <RET>.
The log displayed but initially didn't show anything interesting. When I forced the CPU service recheck, the agent log displayed these messages:
D nrpe Accepting connection from: 10.144.70.82, count=1
E nrpe Seems we other end is not using ssl: unknown protocol
c:\source\master\include\socket/connection.hpp:273
E nrpe Please review the ssl option as well as ssl options in settings.
c:\source\master\include\socket/connection.hpp:274
So a connection was made between the server and agent successfully. I'll need to fix the server's SSL options, but that's another topic.