Page 2 of 2

Re: Check Error, SSL Handshake and Return Code 255

Posted: Fri Aug 28, 2015 6:14 am
by gpi
jdalrymple wrote:Cleaned up and modified slightly - please try:

Code: Select all

[/settings/default]
timeout = 30
allowed hosts = XXX.XXX.XXX.XXX
[/modules]
CheckHelpers = 0
Scheduler = 0
NRPEServer = enabled
CheckSystem = enabled
NSClientServer = 1
CheckExternalScripts = enabled
NSCAClient = 1
CheckEventLog = 1
CheckNSCP = enabled
CheckDisk = enabled
[/settings/NRPE/server]
use ssl = true
allow nasty characters = true
port = 5666
insecure = true
allow arguments = true
[/settings/external scripts/alias]
alias_volumes_loose = check_drivesize
alias_volumes = check_drivesize
alias_sched_all = check_tasksched show-all "syntax=${title}: ${exit_code}" "crit=exit_code ne 0"
alias_process_hung = check_process "filter=is_hung" "crit=count>0"
alias_process = check_process "process=$ARG1$" "crit=state != 'started'"
alias_file_size = check_files "path=$ARG1$" "crit=size > $ARG2$" "top-syntax=${list}" "detail-syntax=${filename] ${size}" max-dir-depth=10
alias_event_log = check_eventlog
alias_service_ex = check_service "exclude=Net Driver HPZ12" "exclude=Pml Driver HPZ12" exclude=stisvc
alias_disk = check_drivesize
alias_cpu_ex = check_cpu "warn=load > $ARG1$" "crit=load > $ARG2$" time=5m time=1m time=30s
alias_file_age = check_files "path=$ARG1$" "crit=written > $ARG2$" "top-syntax=${list}" "detail-syntax=${filename] ${written}" max-dir-depth=10
alias_process_stopped = check_process "process=$ARG1$" "crit=state != 'stopped'"
alias_service = check_service
default =
alias_cpu = check_cpu
alias_mem = check_memory
alias_process_count = check_process "process=$ARG1$" "warn=count > $ARG2$" "crit=count > $ARG3$"
alias_up = check_uptime
alias_disk_loose = check_drivesize
alias_sched_task = check_tasksched show-all "filter=title eq '$ARG1$'" "detail-syntax=${title} (${exit_code})" "crit=exit_code ne 0"
alias_sched_long = check_tasksched "filter=status = 'running'" "detail-syntax=${title} (${most_recent_run_time})" "crit=most_recent_run_time < -$ARG1$"
[/settings/external scripts/scripts]
default =
[/settings/external scripts/wrappings]
vbs = cscript.exe //T:30 //NoLogo scripts\\lib\\wrapper.vbs %SCRIPT% %ARGS%
bat = scripts\\%SCRIPT% %ARGS%
ps1 = cmd /c echo scripts\\%SCRIPT% %ARGS%; exit($lastexitcode) | powershell.exe -command -
[/settings/eventlog/real-time/filters]
default =
Also note all 4.0+ versions of nsclient use the same nsclient.ini config file syntax. I strongly recommend you get all your hosts to a more current version so you're not maintaining both the old style and the new style config files. 0.3.x has been deprecated by the developer for some time.
Hello,

I updatep the nsclient.ini but the check is still not working...

Code: Select all

[root@nagiosxi libexec]# ./check_nrpe -H XXX.XXX.XXX.XXX
CHECK_NRPE: Error - Could not complete SSL handshake.
[root@nagiosxi libexec]#
The log gives the following error:

Code: Select all

2015-08-28 12:21:41: error:D:\source\nscp\include\socket/connection.hpp:243: Failed to establish secure connection: an existing connection was forcibly closed by the remote host: 1862
Any ideas? Is there a way to debug this process so we can get more detailed info?

Regarding the client versions, we are planning to update all of them to the latest version, that will be the next step.

Thanks.

J

Re: Check Error, SSL Handshake and Return Code 255

Posted: Fri Aug 28, 2015 11:54 am
by lmiltchev
I updatep the nsclient.ini but the check is still not working...
Did you restart the NSClient++ service on the Windows box after making the changes to the nsclient.ini file? Can you post the entire nsclient.ini file? Hide the sensitive info.

Run the following command on the Nagios XI server from the command line and show the output:

Code: Select all

nmap <client ip> -p 5666