Hi Team,
We are getting below error message very frequently for windows server metrics in nagios
"CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages"
When I login to windows server and check for nsclient.log , I have below entries during the same time.
2018-08-30 05:47:21: error:c:\source\master\include\scheduler\simple_scheduler.cpp:189: Ran scheduled item 1 10 seconds to late from thread 100
2018-08-30 05:47:35: error:c:\source\master\include\socket/connection.hpp:139: Socket was unexpectedly closed trying to send data (possibly check your timeout settings)
2018-08-30 05:47:35: error:c:\source\master\include\socket/connection.hpp:139: Socket was unexpectedly closed trying to send data (possibly check your timeout settings)
2018-08-30 06:22:04: error:c:\source\master\include\socket/connection.hpp:139: Socket was unexpectedly closed trying to send data (possibly check your timeout settings)
2018-08-30 06:22:10: error:c:\source\master\include\socket/connection.hpp:139: Socket was unexpectedly closed trying to send data (possibly check your timeout settings)
Infact all necessary options are enabled in nsclient.ini file
; Undocumented section
[/settings/NRPE/server]
allow arguments = true
allow nasty characters = true
allow arguments=true
allowed hosts = 127.0.0.1
port = 5666
fssl options = no-sslv2,no-sslv3
ssl options = no-sslv2,no-sslv3
verify mode = none
insecure = true
; Undocumented section
[/modules]
; NRPEServer - A server that listens for incoming NRPE connection and processes incoming requests.
NRPEServer = 1
Please help me on fixing the issue.
Regards,
Mohan Gandhi
check_nrpe issues
Re: check_nrpe issues
Here is a previous thread with related information:
https://support.nagios.com/forum/viewto ... 16&t=48805
A few questions:
https://support.nagios.com/forum/viewto ... 16&t=48805
A few questions:
- What are these check_nrpe checks performing? Are they running scripts that might be taking longer than 60 seconds to execute?
- What version of NSClient++ are you using?
- What operating system and version is this machine using?
Former Nagios employee
https://www.mcapra.com/
https://www.mcapra.com/
Re: check_nrpe issues
Can you please answer mcapra's questions?
Also, you have the following line under the [/settings/NRPE/server] section:
You need to remove this line, provided you specified the Nagios XI server's IP on the "allowed hosts" line under the [/settings/default] section. Alternatively, you can add the Nagios XI server's IP on this line. You can remove one of the these lines:
You don't need two. Comment out these two lines, so that they would look like this:
and add these two lines:
Save, exit and restart the nsclient++ service.
Let us know if this helped.
Also, you have the following line under the [/settings/NRPE/server] section:
Code: Select all
allowed hosts = 127.0.0.1Code: Select all
allow arguments = trueCode: Select all
# fssl options = no-sslv2,no-sslv3
# ssl options = no-sslv2,no-sslv3Code: Select all
extended response = 0
allowed ciphers = ALL:!MD5:@STRENGTHLet us know if this helped.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: check_nrpe issues
Here are the answers for your questions
•What are these check_nrpe checks performing? Are they running scripts that might be taking longer than 60 seconds to execute?
yes, some are running external scripts like vbs and some are using nsclient inbuit scripts for server cpu usage and I don't see them taking more that 60 seconds
•What version of NSClient++ are you using?
We have upgraded nsclient version to 0.5.1.44 a month back
•What operating system and version is this machine using?
Server 2012 R2 Standard
As suggested above by lmiltchev, I have made changes to [/settings/NRPE/server] section as below and restarted nsclient service
[/settings/NRPE/server]
allow nasty characters = true
allowed hosts = 127.0.0.1,172.26.176.56,172.29.173.117,172.26.176.57,172.29.173.118,172.26.172.11,172.29.173.119,172.26.172.12,172.29.173.120,172.26.172.79,172.26.172.80,172.26.172.81,172.26.172.82,172.26.172.83,172.29.168.38,172.26.238.5,172.29.168.36,172.26.238.6,172.26.238.15,172.26.238.16,172.26.238.17,172.26.238.18,172.26.238.19,172.26.238.23,172.26.238.28,172.26.238.37,172.26.238.188,172.26.238.199,172.26.238.200,172.26.238.204,172.26.238.205,172.26.238.207,172.26.238.208,172.26.238.209,172.26.238.210,172.26.238.217,172.26.238.218,172.26.238.221,172.26.238.228,172.26.238.229,172.26.238.231,172.26.238.232,172.29.168.37,172.26.238.248,172.26.238.250,172.29.173.111
port = 5666
#fssl options = no-sslv2,no-sslv3
#ssl options = no-sslv2,no-sslv3
verify mode = none
insecure = true
extended response = 0
allowed ciphers = ALL:!MD5:@STRENGTH
After doing this, I saw below error from nsclient.log
Exception processing request: Request contained arguments (not currently allowed, check the allow arguments option).
so I have added line "allow arguments = true" back to [/settings/NRPE/server] section
and restarted nsclient service
Now I see same kind of error again
CHECK_NRPE: No output returned from daemon
and after doing all these below are the errors I found in nsclient.log
2018-08-31 01:37:26: error:c:\source\master\include\scheduler\simple_scheduler.cpp:189: Ran scheduled item 1 543 seconds to late from thread 100
2018-08-31 01:48:54: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:48:54: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:48:59: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:48:59: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:01: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:01: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:02: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:02: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:02: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_drivesize
2018-08-31 01:49:06: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:06: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:06: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_drivesize
2018-08-31 01:49:06: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:06: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:11: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:11: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:24: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:24: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:31: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:31: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:34: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:34: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:43: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:43: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:43: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_pdh
2018-08-31 01:49:44: debug:c:\source\master\service\logger\nsclient_logger.cpp:52: Creating logger: threaded-file
2018-08-31 01:52:18: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:52:18: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:52:19: debug:c:\source\master\service\logger\nsclient_logger.cpp:52: Creating logger: threaded-file
•What are these check_nrpe checks performing? Are they running scripts that might be taking longer than 60 seconds to execute?
yes, some are running external scripts like vbs and some are using nsclient inbuit scripts for server cpu usage and I don't see them taking more that 60 seconds
•What version of NSClient++ are you using?
We have upgraded nsclient version to 0.5.1.44 a month back
•What operating system and version is this machine using?
Server 2012 R2 Standard
As suggested above by lmiltchev, I have made changes to [/settings/NRPE/server] section as below and restarted nsclient service
[/settings/NRPE/server]
allow nasty characters = true
allowed hosts = 127.0.0.1,172.26.176.56,172.29.173.117,172.26.176.57,172.29.173.118,172.26.172.11,172.29.173.119,172.26.172.12,172.29.173.120,172.26.172.79,172.26.172.80,172.26.172.81,172.26.172.82,172.26.172.83,172.29.168.38,172.26.238.5,172.29.168.36,172.26.238.6,172.26.238.15,172.26.238.16,172.26.238.17,172.26.238.18,172.26.238.19,172.26.238.23,172.26.238.28,172.26.238.37,172.26.238.188,172.26.238.199,172.26.238.200,172.26.238.204,172.26.238.205,172.26.238.207,172.26.238.208,172.26.238.209,172.26.238.210,172.26.238.217,172.26.238.218,172.26.238.221,172.26.238.228,172.26.238.229,172.26.238.231,172.26.238.232,172.29.168.37,172.26.238.248,172.26.238.250,172.29.173.111
port = 5666
#fssl options = no-sslv2,no-sslv3
#ssl options = no-sslv2,no-sslv3
verify mode = none
insecure = true
extended response = 0
allowed ciphers = ALL:!MD5:@STRENGTH
After doing this, I saw below error from nsclient.log
Exception processing request: Request contained arguments (not currently allowed, check the allow arguments option).
so I have added line "allow arguments = true" back to [/settings/NRPE/server] section
and restarted nsclient service
Now I see same kind of error again
CHECK_NRPE: No output returned from daemon
and after doing all these below are the errors I found in nsclient.log
2018-08-31 01:37:26: error:c:\source\master\include\scheduler\simple_scheduler.cpp:189: Ran scheduled item 1 543 seconds to late from thread 100
2018-08-31 01:48:54: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:48:54: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:48:59: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:48:59: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:01: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:01: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:02: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:02: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:02: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_drivesize
2018-08-31 01:49:06: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:06: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:06: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_drivesize
2018-08-31 01:49:06: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:06: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:11: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:11: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:24: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:24: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:31: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:31: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:34: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:34: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:43: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:49:43: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:49:43: error:c:\source\master\modules\NSClientServer\NSClientServer.cpp:160: Unknown command: check_pdh
2018-08-31 01:49:44: debug:c:\source\master\service\logger\nsclient_logger.cpp:52: Creating logger: threaded-file
2018-08-31 01:52:18: error:c:\source\master\service\NSClient++.cpp:840: Failed to process command: Library is not loaded
2018-08-31 01:52:18: error:c:\source\master\include\nscapi\nscapi_core_wrapper.cpp:189: Failed to execute query
2018-08-31 01:52:19: debug:c:\source\master\service\logger\nsclient_logger.cpp:52: Creating logger: threaded-file
Re: check_nrpe issues
Even after doing the changes that were said by you, I still see same error message that im getting as below
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
Re: check_nrpe issues
Can you post the entire NSC.ini or nsclient.ini (depending on the version of nsclient that you are using) on the forum?
Be sure to check out our Knowledgebase for helpful articles and solutions!