check_ms_win_disk_load error?
check_ms_win_disk_load error?
Moderator Edit: This thread has been split from another - https://support.nagios.com/forum/viewto ... =6&t=34770
In the future, please create a new thread and link to the old one instead of adding on.
hi to all
post in this topic
so
problem: "bad answer" at plugin
using plugin check_ms_win_disk_load at windows server localy - good answer
PS C:\Program Files (x86)\NSClient++\scripts\powershell> .\check_ms_win_disk_load.ps1 -H localhost -dl C
OK: Drive C: Avg of 2 samples: {Rate (Read: 0.00000MB/s)(Write: 0.00000MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.0
0000w/s)} {Latency (Read: 0.00000ms)(Write: 0.00000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00000ql)} | 'Read_Laten
cy'=0.00000ms 'Write_Latency'=0.00000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00000ql 'Number_of_Reads'=0.00000r/s 'Num
ber_of_Writes'=0.00000w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.00000MB/s
PS C:\Program Files (x86)\NSClient++\scripts\powershell>
but when using on nagios server (centos):
console:
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -n -t 60 -c check_ms_win_disk_load -a '-H 10.25.41.61'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
nagiosxi gui
/usr/local/nagios/libexec/check_nrpe -H 10.25.41.61 -p 5666 -t 60 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
Exception processing request: Request contained arguments (not currently allowed, check the allow arguments option).
using this for manual https://outsideit.net/monitoring-windows-disk-load/
answer correct, but this not what I need
In the future, please create a new thread and link to the old one instead of adding on.
hi to all
post in this topic
so
problem: "bad answer" at plugin
using plugin check_ms_win_disk_load at windows server localy - good answer
PS C:\Program Files (x86)\NSClient++\scripts\powershell> .\check_ms_win_disk_load.ps1 -H localhost -dl C
OK: Drive C: Avg of 2 samples: {Rate (Read: 0.00000MB/s)(Write: 0.00000MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.0
0000w/s)} {Latency (Read: 0.00000ms)(Write: 0.00000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00000ql)} | 'Read_Laten
cy'=0.00000ms 'Write_Latency'=0.00000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00000ql 'Number_of_Reads'=0.00000r/s 'Num
ber_of_Writes'=0.00000w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.00000MB/s
PS C:\Program Files (x86)\NSClient++\scripts\powershell>
but when using on nagios server (centos):
console:
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -n -t 60 -c check_ms_win_disk_load -a '-H 10.25.41.61'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
nagiosxi gui
/usr/local/nagios/libexec/check_nrpe -H 10.25.41.61 -p 5666 -t 60 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
Exception processing request: Request contained arguments (not currently allowed, check the allow arguments option).
using this for manual https://outsideit.net/monitoring-windows-disk-load/
answer correct, but this not what I need
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: check_ms_win_disk_load error?
Welcome back, @terminus.
Do the other NSClient checks work on your XI or all of them are failing? Can you also check the nsclient.log file, or better attach it to your next post?
I'd also like to see nsclient.ini file.
Do the other NSClient checks work on your XI or all of them are failing? Can you also check the nsclient.log file, or better attach it to your next post?
I'd also like to see nsclient.ini file.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: check_ms_win_disk_load error?
in powershell windows server
PS C:\Program Files (x86)\NSClient++\scripts\powershell> .\check_ms_win_disk_load.ps1 -H localhost -dl C
OK: Drive C: Avg of 2 samples: {Rate (Read: 0.00000MB/s)(Write: 0.00000MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.0
0000w/s)} {Latency (Read: 0.00000ms)(Write: 0.00000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00000ql)} | 'Read_Laten
cy'=0.00000ms 'Write_Latency'=0.00000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00000ql 'Number_of_Reads'=0.00000r/s 'Num
ber_of_Writes'=0.00000w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.00000MB/s
PS C:\Program Files (x86)\NSClient++\scripts\powershell>
in nagios server
[root@mon01 libexec]# ./check_nrpe -H myhost -n -c check_ms_win_disk_load -a '-H myhost -ms 5 -dl C'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
[root@mon01 libexec]# ./check_nrpe -H myhost -c check_ms_win_disk_load -a '-H myhost -ms 5 -dl C'
CHECK_NRPE: Error - Could not complete SSL handshake.
[root@mon01 libexec]#
PS C:\Program Files (x86)\NSClient++\scripts\powershell> .\check_ms_win_disk_load.ps1 -H localhost -dl C
OK: Drive C: Avg of 2 samples: {Rate (Read: 0.00000MB/s)(Write: 0.00000MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.0
0000w/s)} {Latency (Read: 0.00000ms)(Write: 0.00000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00000ql)} | 'Read_Laten
cy'=0.00000ms 'Write_Latency'=0.00000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00000ql 'Number_of_Reads'=0.00000r/s 'Num
ber_of_Writes'=0.00000w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.00000MB/s
PS C:\Program Files (x86)\NSClient++\scripts\powershell>
in nagios server
[root@mon01 libexec]# ./check_nrpe -H myhost -n -c check_ms_win_disk_load -a '-H myhost -ms 5 -dl C'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
[root@mon01 libexec]# ./check_nrpe -H myhost -c check_ms_win_disk_load -a '-H myhost -ms 5 -dl C'
CHECK_NRPE: Error - Could not complete SSL handshake.
[root@mon01 libexec]#
You do not have the required permissions to view the files attached to this post.
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: check_ms_win_disk_load error?
@terminus, Your nsclient.ini configuration file looks almost empty. What tutorial did you use to configure it? Here's my configuration as an example. You might copy it over instead of what you have.
And when it's done please use an example in this tutorial to import the path to the PowerShell script in the same config file: https://support.nagios.com/kb/article.php?id=528
After you modified ini file please restart NSClient service from the windows menu.
Code: Select all
# If you want to fill this file with all available options run the following command:
# nscp settings --generate --add-defaults --load-all
# If you want to activate a module and bring in all its options use:
# nscp settings --activate-module <MODULE NAME> --add-defaults
# For details run: nscp settings --help
; TODO
[/settings/default]
; Undocumented key
password = 12345
; Undocumented key
allowed hosts = 127.0.0.1,::1,10.0.0.0/8
; CACHE ALLOWED HOSTS - If host names (DNS entries) should be cached, improves speed and security somewhat but won't allow you to have dynamic IPs for your Nagios server.
cache allowed hosts = 1
; TIMEOUT - Timeout when reading packets on incoming sockets. If the data has not arrived within this time we will bail out.
timeout = 30
; TODO
[/modules]
; Undocumented key
CheckHelpers = 1
; Undocumented key
CheckEventLog = 1
; Undocumented key
CheckNSCP = 1
; Undocumented key
CheckSystem = 1
; Undocumented key
NSClientServer = 1
; NRPEServer - A server that listens for incoming NRPE connection and processes incoming requests.
NRPEServer = 1
; CheckExternalScripts - Execute external scripts
CheckExternalScripts = 1
; CheckDisk - CheckDisk can check various file and disk related things.
CheckDisk = 1
; A set of options to configure the real time checks
[/settings/system/windows/real-time]
; Configure which services has to be in which state
[/settings/system/windows/service mapping]
; TODO
[/settings/system/windows/counters/default]
; TODO
[/settings/system/windows/counters]
; TODO
[/settings/log/file]
; TODO
[/settings/log]
; LOG LEVEL - Log level to use. Available levels are error,warning,info,debug,trace
level = debug
; DATEMASK - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
date format = %Y-%m-%d %H:%M:%S
; FILENAME - The file to write log data to. Set this to none to disable log to file.
file name = ${exe-path}/nsclient.log
; TODO
[/settings/system/windows]
; DEFAULT LENGTH - Used to define the default interval for range buffer checks (ie. CPU).
default buffer length = 1h
; TODO
[/settings/external scripts/scripts/default]
; IGNORE PERF DATA - Do not parse performance data from the output
ignore perfdata = 1
; A list of wrapped scripts (ie. scruts using a template mechanism). The template used will be defined by the extension of the script.
[/settings/external scripts/wrapped scripts]
check_windows_time = check_windows_time.bat.pool.ntp.org $ARG1$ $ARG2$
; TODO
[/settings/external scripts/alias]
; TODO
[/settings/eventlog/real-time/filters/default]
; EMPTY MESSAGE - The message to display if nothing matches the filter (generally considered the ok state).
empty message = eventlog found no records
; MAGIMUM AGE - How long before reporting "ok". If this is set to "false" no periodic ok messages will be reported only errors.
maximum age = 5m
; A set of filters to use in real-time mode
[/settings/eventlog/real-time/filters]
; TODO
[/settings/eventlog/real-time]
; STARTUP AGE - The initial age to scan when starting NSClient++
startup age = 30m
; REAL TIME CHECKING - Spawns a background thread which detects issues and reports them back instantly.
enabled = 0
; LOGS TO CHECK - Comma separated list of logs to check
log = application,system
; DEBUG - Log missed records (useful to detect issues with filters) not useful in production as it is a bit of a resource hog.
debug = 0
; A list of scripts available to run from the CheckExternalScripts module. Syntax is: <command>=<script> <arguments>
[/settings/external scripts/scripts]
restart_service = scripts\restart_service.bat "$ARG1$"
check_windows_time=scripts\check_windows_time.bat $ARG1$
; TODO
[/settings/external scripts/alias/default]
; TODO
[/settings/shared session]
; TODO
[/settings/crash]
; RESTART SERVICE NAME - The url to submit crash reports to
restart target = NSCP
; CRASH ARCHIVE LOCATION - The folder to archive crash dumps in
archive folder = ${crash-folder}
; RESTART - Submit crash reports to nsclient.org (or your configured submission server)
restart = true
; SUBMISSION URL - The url to submit crash reports to
submit url = https://crash.nsclient.org/post
; ARCHIVE CRASHREPORTS - Archive crash reports in the archive folder
archive = true
; A set of filters to use in real-time mode
[/settings/system/windows/real-time/checks]
; TODO
[/settings/NSClient/server]
; ENABLE SSL ENCRYPTION - This option controls if SSL should be enabled.
use ssl = 0
; PORT NUMBER - Port to use for check_nt.
port = 12489
; PERFORMANCE DATA - Send performance data back to Nagios (set this to 0 to remove all performance data).
performance data = 1
; TODO
[/settings/external scripts]
; COMMAND TIMEOUT - The maximum time in seconds that a command can execute. (if more then this execution will be aborted). NOTICE this only affects external commands not internal ones.
timeout = 80
; COMMAND ARGUMENT PROCESSING - This option determines whether or not the we will allow clients to specify arguments to commands that are executed.
allow arguments = true
; 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 = true
; TODO
[/paths]
; Path for shared-path -
shared-path = C:\Program Files\NSClient++
; Path for module-path -
module-path = ${shared-path}/modules
; Path for crash-folder -
crash-folder = ${shared-path}/crash-dumps
; Path for exe-path -
exe-path = C:\Program Files\NSClient++
; Path for certificate-path -
certificate-path = ${shared-path}/security
; Path for base-path -
base-path = C:\Program Files\NSClient++
; Files to be included in the configuration
[/includes]
; TODO
[/settings/eventlog]
; DEBUG - Log more information when filtering (useful to detect issues with filters) not useful in production as it is a bit of a resource hog.
debug = 0
; LOOKUP NAMES - Lookup the names of eventlog files
lookup names = 1
; BUFFER_SIZE - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
buffer size = 131072
; TODO
[/settings/external scripts/wrappings]
; BATCH FILE WRAPPING -
bat = scripts\\%SCRIPT% %ARGS%
; VISUAL BASIC WRAPPING -
vbs = cscript.exe //T:30 //NoLogo scripts\\lib\\wrapper.vbs %SCRIPT% %ARGS%
; POWERSHELL WRAPPING -
ps1 = cmd /c echo If (-Not (Test-Path "scripts\%SCRIPT%") ) { Write-Host "UNKNOWN: Script `"%SCRIPT%`" not found."; exit(3) }; scripts\%SCRIPT% $ARGS$; exit($lastexitcode) | powershell.exe /noprofile -command -
; TODO
[/settings/NRPE/server]
; PORT NUMBER - Port to use for NRPE.
port = 5666
; 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 = 1
; ENABLE SSL ENCRYPTION - This option controls if SSL should be enabled.
use ssl = 1
; COMMAND ARGUMENT PROCESSING - This option determines whether or not the we will allow clients to specify arguments to commands that are executed.
allow arguments = true
; 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 = true
; ALLOW INSECURE CHIPHERS and ENCRYPTION - Only enable this if you are using legacy check_nrpe client.
insecure = false
; Undocumented key
veryify mode = none
; Undocumented key
ssl options = no-sslv2,no-sslv3
; Undocumented key
verify mode = peer-certAfter you modified ini file please restart NSClient service from the windows menu.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: check_ms_win_disk_load error?
thanks for your answer
so
apply your example nsclient.ini and restart nsclient service in windows menu
in nagios server console
[root@mon01 libexec]# ./check_nrpe -H myhost -n -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
[root@mon01 libexec]# ./check_nrpe -H myhost -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages..
[root@mon01 libexec]#
in nsclient.log
2017-11-29 21:49:46: debug:c:\source\master\include\nrpe/server/protocol.hpp:72: Accepting connection from: 10.251.80.30, count=1
2017-11-29 21:49:46: error:c:\source\master\include\socket/connection.hpp:238: Seems we cant agree on SSL: no shared cipher
2017-11-29 21:49:46: error:c:\source\master\include\socket/connection.hpp:239: Please review the insecure options as well as ssl options in settings.
2017-11-29 21:50:05: debug:c:\source\master\include\nrpe/server/protocol.hpp:72: Accepting connection from: 10.251.80.30, count=1
2017-11-29 21:50:05: error:c:\source\master\include\socket/connection.hpp:241: Seems we other end is not using ssl: unknown protocol
2017-11-29 21:50:05: error:c:\source\master\include\socket/connection.hpp:242: Please review the ssl option as well as ssl options in settings.
so
apply your example nsclient.ini and restart nsclient service in windows menu
in nagios server console
[root@mon01 libexec]# ./check_nrpe -H myhost -n -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.
[root@mon01 libexec]# ./check_nrpe -H myhost -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages..
[root@mon01 libexec]#
in nsclient.log
2017-11-29 21:49:46: debug:c:\source\master\include\nrpe/server/protocol.hpp:72: Accepting connection from: 10.251.80.30, count=1
2017-11-29 21:49:46: error:c:\source\master\include\socket/connection.hpp:238: Seems we cant agree on SSL: no shared cipher
2017-11-29 21:49:46: error:c:\source\master\include\socket/connection.hpp:239: Please review the insecure options as well as ssl options in settings.
2017-11-29 21:50:05: debug:c:\source\master\include\nrpe/server/protocol.hpp:72: Accepting connection from: 10.251.80.30, count=1
2017-11-29 21:50:05: error:c:\source\master\include\socket/connection.hpp:241: Seems we other end is not using ssl: unknown protocol
2017-11-29 21:50:05: error:c:\source\master\include\socket/connection.hpp:242: Please review the ssl option as well as ssl options in settings.
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: check_ms_win_disk_load error?
@terminus, I updated a couple more configs in ini file. Please replace the contents of your ini one more time and restart NSClient++ service. Let us know if you're still getting the same error.
Code: Select all
# If you want to fill this file with all available options run the following command:
# nscp settings --generate --add-defaults --load-all
# If you want to activate a module and bring in all its options use:
# nscp settings --activate-module <MODULE NAME> --add-defaults
# For details run: nscp settings --help
; TODO
[/settings/default]
; Undocumented key
password = 12345
; Undocumented key
allowed hosts = 127.0.0.1,::1,10.0.0.0/8
; CACHE ALLOWED HOSTS - If host names (DNS entries) should be cached, improves speed and security somewhat but won't allow you to have dynamic IPs for your Nagios server.
cache allowed hosts = 1
; TIMEOUT - Timeout when reading packets on incoming sockets. If the data has not arrived within this time we will bail out.
timeout = 30
; TODO
[/modules]
; Undocumented key
CheckHelpers = 1
; Undocumented key
CheckEventLog = 1
; Undocumented key
CheckNSCP = 1
; Undocumented key
CheckSystem = 1
; Undocumented key
NSClientServer = 1
; NRPEServer - A server that listens for incoming NRPE connection and processes incoming requests.
NRPEServer = 1
; CheckExternalScripts - Execute external scripts
CheckExternalScripts = 1
; CheckDisk - CheckDisk can check various file and disk related things.
CheckDisk = 1
; A set of options to configure the real time checks
[/settings/system/windows/real-time]
; Configure which services has to be in which state
[/settings/system/windows/service mapping]
; TODO
[/settings/system/windows/counters/default]
; TODO
[/settings/system/windows/counters]
; TODO
[/settings/log/file]
; TODO
[/settings/log]
; LOG LEVEL - Log level to use. Available levels are error,warning,info,debug,trace
level = debug
; DATEMASK - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
date format = %Y-%m-%d %H:%M:%S
; FILENAME - The file to write log data to. Set this to none to disable log to file.
file name = ${exe-path}/nsclient.log
; TODO
[/settings/system/windows]
; DEFAULT LENGTH - Used to define the default interval for range buffer checks (ie. CPU).
default buffer length = 1h
; TODO
[/settings/external scripts/scripts/default]
; IGNORE PERF DATA - Do not parse performance data from the output
ignore perfdata = 1
; A list of wrapped scripts (ie. scruts using a template mechanism). The template used will be defined by the extension of the script.
[/settings/external scripts/wrapped scripts]
check_windows_time = check_windows_time.bat.pool.ntp.org $ARG1$ $ARG2$
; TODO
[/settings/external scripts/alias]
; TODO
[/settings/eventlog/real-time/filters/default]
; EMPTY MESSAGE - The message to display if nothing matches the filter (generally considered the ok state).
empty message = eventlog found no records
; MAGIMUM AGE - How long before reporting "ok". If this is set to "false" no periodic ok messages will be reported only errors.
maximum age = 5m
; A set of filters to use in real-time mode
[/settings/eventlog/real-time/filters]
; TODO
[/settings/eventlog/real-time]
; STARTUP AGE - The initial age to scan when starting NSClient++
startup age = 30m
; REAL TIME CHECKING - Spawns a background thread which detects issues and reports them back instantly.
enabled = 0
; LOGS TO CHECK - Comma separated list of logs to check
log = application,system
; DEBUG - Log missed records (useful to detect issues with filters) not useful in production as it is a bit of a resource hog.
debug = 0
; A list of scripts available to run from the CheckExternalScripts module. Syntax is: <command>=<script> <arguments>
[/settings/external scripts/scripts]
restart_service = scripts\restart_service.bat "$ARG1$"
check_windows_time=scripts\check_windows_time.bat $ARG1$
; TODO
[/settings/external scripts/alias/default]
; TODO
[/settings/shared session]
; TODO
[/settings/crash]
; RESTART SERVICE NAME - The url to submit crash reports to
restart target = NSCP
; CRASH ARCHIVE LOCATION - The folder to archive crash dumps in
archive folder = ${crash-folder}
; RESTART - Submit crash reports to nsclient.org (or your configured submission server)
restart = true
; SUBMISSION URL - The url to submit crash reports to
submit url = https://crash.nsclient.org/post
; ARCHIVE CRASHREPORTS - Archive crash reports in the archive folder
archive = true
; A set of filters to use in real-time mode
[/settings/system/windows/real-time/checks]
; TODO
[/settings/NSClient/server]
; ENABLE SSL ENCRYPTION - This option controls if SSL should be enabled.
use ssl = 0
; PORT NUMBER - Port to use for check_nt.
port = 12489
; PERFORMANCE DATA - Send performance data back to Nagios (set this to 0 to remove all performance data).
performance data = 1
; TODO
[/settings/external scripts]
; COMMAND TIMEOUT - The maximum time in seconds that a command can execute. (if more then this execution will be aborted). NOTICE this only affects external commands not internal ones.
timeout = 80
; COMMAND ARGUMENT PROCESSING - This option determines whether or not the we will allow clients to specify arguments to commands that are executed.
allow arguments = true
; 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 = true
; TODO
[/paths]
; Path for shared-path -
shared-path = C:\Program Files\NSClient++
; Path for module-path -
module-path = ${shared-path}/modules
; Path for crash-folder -
crash-folder = ${shared-path}/crash-dumps
; Path for exe-path -
exe-path = C:\Program Files\NSClient++
; Path for certificate-path -
certificate-path = ${shared-path}/security
; Path for base-path -
base-path = C:\Program Files\NSClient++
; Files to be included in the configuration
[/includes]
; TODO
[/settings/eventlog]
; DEBUG - Log more information when filtering (useful to detect issues with filters) not useful in production as it is a bit of a resource hog.
debug = 0
; LOOKUP NAMES - Lookup the names of eventlog files
lookup names = 1
; BUFFER_SIZE - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
buffer size = 131072
; TODO
[/settings/external scripts/wrappings]
; BATCH FILE WRAPPING -
bat = scripts\\%SCRIPT% %ARGS%
; VISUAL BASIC WRAPPING -
vbs = cscript.exe //T:30 //NoLogo scripts\\lib\\wrapper.vbs %SCRIPT% %ARGS%
; POWERSHELL WRAPPING -
ps1 = cmd /c echo If (-Not (Test-Path "scripts\%SCRIPT%") ) { Write-Host "UNKNOWN: Script `"%SCRIPT%`" not found."; exit(3) }; scripts\%SCRIPT% $ARGS$; exit($lastexitcode) | powershell.exe /noprofile -command -
; TODO
[/settings/NRPE/server]
; VERIFY MODE - Comma separated list of verification flags to set on the SSL socket. default-workarounds Various workarounds for what I understand to be broken ssl implementations no-sslv2 Do not use the SSLv2 protocol. no-sslv3 Do not use the SSLv3 protocol. no-tlsv1 Do not use the TLSv1 protocol. single-dh-use Always create a new key when using temporary/ephemeral DH parameters. This option must be used to prevent small subgroup attacks, when the DH parameters were not generated using "strong" primes (e.g. when using DSA-parameters).
ssl options =
; VERIFY MODE - Comma separated list of verification flags to set on the SSL socket. none The server will not send a client certificate request to the client, so the client will not send a certificate. peer The server sends a client certificate request to the client and the certificate returned (if any) is checked. fail-if-no-cert if the client did not return a certificate, the TLS/SSL handshake is immediately terminated. This flag must be used together with peer. peer-cert Alias for peer and fail-if-no-cert. workarounds Various bug workarounds. single Always create a new key when using tmp_dh parameters. client-once Only request a client certificate on the initial TLS/SSL handshake. This flag must be used together with verify-peer
verify mode = none
; ALLOW INSECURE CHIPHERS and ENCRYPTION - Only enable this if you are using legacy check_nrpe client.
insecure = true
allow arguments = true
allow nasty characters = true
; ENABLE SSL ENCRYPTION - This option controls if SSL should be enabled.
use ssl = 1
; PORT NUMBER - Port to use for NRPE.
port = 5666As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: check_ms_win_disk_load error?
@npolovenko
thanks for your answer
so
apply your new example nsclient.ini and restart nsclient service in windows menu
but i'm correct you example nsclient config for manual https://outsideit.net/monitoring-windows-disk-load/
add this string
check_ms_win_disk_load = cmd /c echo scripts\powershell\check_ms_win_disk_load.ps1 $ARG1$; exit $LastExitCode | powershell.exe /noprofile -command -
than
in nagios server console
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
Unknown command(s): check_ms_win_disk_load
[root@mon01 libexec]#
add log nsclient
thanks for your answer
so
apply your new example nsclient.ini and restart nsclient service in windows menu
but i'm correct you example nsclient config for manual https://outsideit.net/monitoring-windows-disk-load/
add this string
check_ms_win_disk_load = cmd /c echo scripts\powershell\check_ms_win_disk_load.ps1 $ARG1$; exit $LastExitCode | powershell.exe /noprofile -command -
than
in nagios server console
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
Unknown command(s): check_ms_win_disk_load
[root@mon01 libexec]#
add log nsclient
You do not have the required permissions to view the files attached to this post.
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: check_ms_win_disk_load error?
@terminus
So in the nsclient.ini file look for this section:
Inside there add the following definition from a new line:
And don't forget to put the actual script check_ms_win_disk_load.ps1 in the NSClient++/scripts folder.
When done please restart NSClient++ service one more time.
Let us know if that worked.
That's a better output. Seems like NRPE started to work.Unknown command(s): check_ms_win_disk_load
So in the nsclient.ini file look for this section:
Code: Select all
[/settings/external scripts/scripts]Code: Select all
check_ms_win_disk_load = cmd /c echo scripts\check_ms_win_disk_load.ps1 $ARG1$; exit $LastExitCode | powershell.exe /noprofile -command -When done please restart NSClient++ service one more time.
Let us know if that worked.
You do not have the required permissions to view the files attached to this post.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: check_ms_win_disk_load error?
@npolovenko
you are best
yes, it's work !
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
OK: Drive C: Avg of 5 samples: {Rate (Read: 0.00000MB/s)(Write: 0.01156MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.39448w/s)} {Latency (Read: 0.00000ms)(Write: 0.08000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00016ql)} | 'Read_Latency'=0.00000ms 'Write_Latency'=0.08000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00016ql 'Number_of_Reads'=0.00000r/s 'Number_of_Writes'=0.39448w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.01156MB/s
[root@mon01 libexec]#
thank you very much
!!!!!!
you are best
yes, it's work !
[root@mon01 libexec]# ./check_nrpe -H 10.25.41.61 -c check_ms_win_disk_load -a '-dl C -ms 5 -rqw 20 -rqc 50'
OK: Drive C: Avg of 5 samples: {Rate (Read: 0.00000MB/s)(Write: 0.01156MB/s)} {Avg Nr of (Reads: 0.00000r/s)(Writes: 0.39448w/s)} {Latency (Read: 0.00000ms)(Write: 0.08000ms)} {Queue Length (Read: 0.00000ql)(Write: 0.00016ql)} | 'Read_Latency'=0.00000ms 'Write_Latency'=0.08000ms 'Read_Queue'=0.00000ql 'Write_Queue'=0.00016ql 'Number_of_Reads'=0.00000r/s 'Number_of_Writes'=0.39448w/s 'Read_Rate'=0.00000MB/s 'Write_Rate'=0.01156MB/s
[root@mon01 libexec]#
thank you very much
!!!!!!
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: check_ms_win_disk_load error?
@terminus, Nice, you're welcome! I will close this thread as resolved now.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.