Page 1 of 3

check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 5:28 am
by Naveed
Hello,


I am monitoring my windows server with check_nrpe.

I have set threshold warning = 85 and critical = 95

check_nrpe!check_drivesize! "warn=free<15%""crit=free<05%" drive=*

My one drive is 80 % utilized, its not working, kindly suggest

Thank you!

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 9:54 am
by rkennedy
Can you show us the full input / output of running the check from the command line?

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 10:05 am
by Naveed
Thank you rkennedy

Command from CCM

check_nrpe!check_drivesize! "warn=free le 10%" "crit=free le 05%"

I have attached screenshot of monitoring command.

Let me know if need anything else.

I want to monitor check_memory and check_cpu with defined thresholds.

Thank you very much!

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 11:12 am
by Naveed
Dear,

its getting hot, please assist.

Thank you!

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 11:20 am
by rkennedy
rkennedy wrote:Can you show us the full input / output of running the check from the command line?
The CCM doesn't help much as it doesn't have all of the information. Please run it over the CLI, similar to this, but with your parameters - ./check_nrpe -H 192.168.5.47 -c check_drivesize -a "warn=free<95%" "crit=free<90%"

I will need the full input and output, to see exactly what is being returned in the performance data.
Naveed wrote:Dear,

its getting hot, please assist.

Thank you!
Please do not post twice, it does no good except drop you down to the bottom of our dashboard.

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 11:44 am
by Naveed
Sure sir!

I would not paste twice.

I have tried possibly below commands.


[root@AXmonitor libexec]# ./check_nrpe -H 12.3.4 -c check_drivesize -a "warn=free<95%" "crit=free<90%"
Exception processing request: Request command contained illegal metachars!

[root@AXmonitor libexec]# ./check_nrpe -H 1.2.3.4 -c check_drivesize -a 'warn=free<95%' 'crit=free<90%'
Exception processing request: Request command contained illegal metachars!

[root@AXmonitor libexec]# ./check_nrpe -H 1.2.3.4 -c check_drivesize -a 'warn=free\<95%' 'crit=free\<90%'
Exception processing request: Request command contained illegal metachars!

Kindly suggest.

Thank you!

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 11:49 am
by rkennedy
You need to allow nasty characters, take a look at your NSClient++ configuration and add 'allow nasty characters=true' in both of the sections below. If you have it turned off, make sure to replace it.

Code: Select all

[/settings/NRPE/server]
[/settings/external scripts]

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 12:27 pm
by Naveed
Thank you I have enabled both commands in nsclient file after that its working fine now.

My disk utilization is 91%

[root@AXmonitor libexec]# ./check_nrpe -H 1.2.3.4 -c check_drivesize -a "warn=free<90%" "crit=free<98%"
CRITICAL C:\: 114.486GB/126.998GB used, D:\: 9.859GB/284.998GB used|'A:\ free'=0B;0;0;0;0 'C:\ free'=12.51238GB;114.29823;124.45808;0;126.99804 'C:\ free %'=9%;90;98;0;100 'D:\ free'=275.13917GB;256.49823;279.29808;0;284.99804 'D:\ free %'=96%;89;97;0;100

[root@AXmonitor libexec]# ./check_nrpe -H 1.2.3.4 -c check_drivesize -a "warn=free<92%" "crit=free<98%"
CRITICAL C:\: 114.486GB/126.998GB used, D:\: 9.859GB/284.998GB used|'A:\ free'=0B;0;0;0;0 'C:\ free'=12.51238GB;116.8382;124.45808;0;126.99804 'C:\ free %'=9%;92;98;0;100 'D:\ free'=275.13917GB;262.1982;279.29808;0;284.99804 'D:\ free %'=96%;91;97;0;100

[root@AXmonitor libexec]# ./check_nrpe -H 1.2.3.4 -c check_drivesize -a "warn=free<92%" "crit=free<90%"
CRITICAL C:\: 114.486GB/126.998GB used|'A:\ free'=0B;0;0;0;0 'C:\ free'=12.51238GB;116.8382;114.29823;0;126.99804 'C:\ free %'=9%;92;90;0;100 'D:\ free'=275.13917GB;262.1982;256.49823;0;284.99804 'D:\ free %'=96%;91;89;0;100
[root@AXmonitor libexec]#


I have changed the thresholds, but result is always Critical.

I have set thresholds as follows:

Warning = 95 %
Critical = 98 %

But still its showing results Critical rather than to be Warning.

Screenshot is attached as well.

Kindly assist

Thank you!

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 1:58 pm
by rkennedy
I wonder if your A drive is causing the issue since it's 0's across the board, could you check each of them manually to see if that's the case?

Code: Select all

./check_nrpe -H 192.168.5.47 -c check_drivesize -a "warn=free<90%" "crit=free<98%" "drive=c"

Re: check_drivesize in windows with threshold

Posted: Thu Jun 23, 2016 5:00 pm
by Naveed
Thank you for your support!

I have tried your suggested way, but still its not working.

Even I changed drive = d which is only 20 % utilized but due to C drive its showing critical result.

Kindly assist!

Thank you!