check_NRPE gave "Received 0 bytes from daemon"
-
caterpillartce
- Posts: 117
- Joined: Mon Jul 11, 2016 11:22 am
check_NRPE gave "Received 0 bytes from daemon"
Hello,
I am trying to use check_NRPE to monitor physical memory usage on a windows server. This might be the first time check_nrpe is used. Is there anything I need to do to "enable" it as when I "Run the Check Command" when defining the service in CCM, it gives an error "Received 0 bytes from daemon". The nsclient log file has
"2017-07-21 11:57:50: error:c:\source\nscp\include\socket/connection.hpp:243: Failed to establish secure connection: unknown protocol: 252"
This is in NSCLIENT.INI:
[/settings/NRPE/server]
; Undocumented key
ssl options = no-sslv2,no-sslv3
; Undocumented key
; verify mode = peer-cert
; Undocumented key
insecure = true
Thanks!
I am trying to use check_NRPE to monitor physical memory usage on a windows server. This might be the first time check_nrpe is used. Is there anything I need to do to "enable" it as when I "Run the Check Command" when defining the service in CCM, it gives an error "Received 0 bytes from daemon". The nsclient log file has
"2017-07-21 11:57:50: error:c:\source\nscp\include\socket/connection.hpp:243: Failed to establish secure connection: unknown protocol: 252"
This is in NSCLIENT.INI:
[/settings/NRPE/server]
; Undocumented key
ssl options = no-sslv2,no-sslv3
; Undocumented key
; verify mode = peer-cert
; Undocumented key
insecure = true
Thanks!
Re: check_NRPE gave "Received 0 bytes from daemon"
Please attach your entire nsclient.ini so that we can review it, here is generally what needs to be set:
Also, what version of NSClient++ are you using? You can find it listed next to the name in the add/remove programs or programs and features section of the control panel.
Thank you
Code: Select all
[/modules]
; NRPEServer - A server that listens for incoming NRPE connection and processes incoming requests.
NRPEServer = 1
; TODO
[/settings/NRPE/server]
; ALLOW INSECURE CHIPHERS and ENCRYPTION - Only enable this if you are using legacy check_nrpe client.
insecure = 1
; COMMAND ALLOW NASTY META CHARS - This option determines whether or not the we will allow clients to specify nasty (as in |`&><'"\[]{}) characters in arguments.
allow nasty characters = 1
; EXTENDED RESPONSE - Send more then 1 return packet to allow response to go beyond payload size (requires modified client if legacy is true this defaults to false).
extended response = 0
; PORT NUMBER - Port to use for NRPE.
port = 5666
; COMMAND ARGUMENT PROCESSING - This option determines whether or not the we will allow clients to specify arguments to commands that are executed.
allow arguments = 1
; ENABLE SSL ENCRYPTION - This option controls if SSL should be enabled.
use ssl = 1Thank you
-
caterpillartce
- Posts: 117
- Joined: Mon Jul 11, 2016 11:22 am
Re: check_NRPE gave "Received 0 bytes from daemon"
hi, I added port and allow argument based on above. Restarted NSClient service. But it did not help. I will PM you our nsclient.ini. Its version is 0.4.4.19.
Thanks
Thanks
- tacolover101
- Posts: 432
- Joined: Mon Apr 10, 2017 11:55 am
Re: check_NRPE gave "Received 0 bytes from daemon"
i feel like these contradict each other -
try commenting out ssl options if you're fine with insecure mode.
also post your nsclient.log as if it's SSL related, this will usually have more information.
Code: Select all
; Undocumented key
ssl options = no-sslv2,no-sslv3
; Undocumented key
; verify mode = peer-cert
; Undocumented key
insecure = true
also post your nsclient.log as if it's SSL related, this will usually have more information.
Re: check_NRPE gave "Received 0 bytes from daemon"
Are you calling an external script via check_nrpe?
In the majority of the cases, you would also need to set the following:
in the [/modules] section, and:
in [/settings/external scripts] section.
In the majority of the cases, you would also need to set the following:
Code: Select all
CheckExternalScripts = 1Code: Select all
allow nasty characters = 1
allow arguments = 1Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: check_NRPE gave "Received 0 bytes from daemon"
Please post the entire check command you are running from the XI server, you can get it from the Run Check Command button when editing the service.
Thank you
Thank you
-
caterpillartce
- Posts: 117
- Joined: Mon Jul 11, 2016 11:22 am
Re: check_NRPE gave "Received 0 bytes from daemon"
I did all the above, but it is still failing with the same error. Attached please find the nsclient.ini and log file. I removed the allowed hosts for security in the ini file. The error about check_time in the log seems to have been there for ever and not related to check_NRPE.
Thanks!
Thanks!
You do not have the required permissions to view the files attached to this post.
-
caterpillartce
- Posts: 117
- Joined: Mon Jul 11, 2016 11:22 am
Re: check_NRPE gave "Received 0 bytes from daemon"
And this is the check command: (I just wanted to monitor physical memory usage)
$USER1$/check_nrpe -H $HOSTADDRESS$ -n -c CheckMem -a type=physical MaxWarn=$ARG1$ MaxCrit=$ARG2$ ShowAll=long
$USER1$/check_nrpe -H $HOSTADDRESS$ -n -c CheckMem -a type=physical MaxWarn=$ARG1$ MaxCrit=$ARG2$ ShowAll=long
Re: check_NRPE gave "Received 0 bytes from daemon"
Can you post the entire nsclient.ini file? You can redact it / remove sensitive info.
Run the following commands from the Nagios XI server and show the output:
Run the following commands from the Nagios XI server and show the output:
Code: Select all
/usr/local/nagios/libexec/check_nrpe -H <client ip>
/usr/local/nagios/libexec/check_nrpe -H <client ip> -c alias_mem
/usr/local/nagios/libexec/check_nrpe -H <client ip> -c CheckMem -a type=physical MaxWarn=$ARG1$ MaxCrit=$ARG2$ ShowAll=longBe sure to check out our Knowledgebase for helpful articles and solutions!
-
caterpillartce
- Posts: 117
- Joined: Mon Jul 11, 2016 11:22 am
Re: check_NRPE gave "Received 0 bytes from daemon"
The attached nsclient.ini is the entire file. The only thing I removed was the IP addresses of the allowed hosts.
I ran the commands on the Linux Nagios server and they all seemed to have worked fine. Attached is the screenshot.
Thanks!
I ran the commands on the Linux Nagios server and they all seemed to have worked fine. Attached is the screenshot.
Thanks!
You do not have the required permissions to view the files attached to this post.