Check Disks on Windows Server
Posted: Mon Mar 30, 2015 8:33 am
We have the following command configured to check the disk space of all drives apart from the c drive (we have a separate command for the c (system) drive).
Command view
$USER1$/check_nrpe -H $HOSTADDRESS$ -c CheckDriveSize -a $ARG1$ $ARG2$ $ARG3$
Arg1= MaxWarn=10G
Arg2= MaxCrit=5G
Arg3= FilterType=Fixed CheckAllOthers Drive=C:
Based on the variety of information from Nagios and NSClient++ the above command should return the diskspace for all drives on a server excluding the c drive.
However, when testing the command from the web interface the below is returned:
COMMAND: /usr/local/nagios/libexec/check_nrpe -H <hostname> -c CheckDriveSize -a MaxWarn=10G MaxCrit=5G FilterType=FIXED CheckAllOthers Drive=C:
OUTPUT: CRITICAL C:: Total: 49.656GB - Used: 32.185GB (65%) - Free: 17.471GB (35%)|'C: used'=32.18547GB;10;5;0;49.65624 'C: used %'=64%;20;10;0;100
If I remove the Drive=C: we can see all drives:
COMMAND: /usr/local/nagios/libexec/check_nrpe -H htv440650 -c CheckDriveSize -a MaxWarn=10G MaxCrit=5G FilterType=FIXED CheckAllOthers
OUTPUT: CRITICAL C:\: Total: 49.656GB - Used: 32.186GB (65%) - Free: 17.47GB (35%), E:\: Total: 299.998GB - Used: 248.296GB (83%) - Free: 51.702GB (17%), F:\: Total: 599.873GB - Used: 297.601GB (50%) - Free: 302.272GB (50%), G:\: Total: 1.99TB - Used: 1.637TB (83%) - Free: 361.48GB (17%), H:\: Total: 1.221TB - Used: 970.921GB (78%) - Free: 278.951GB (22%), I:\: Total: 349.873GB - Used: 161.326GB (47%) - Free: 188.547GB (53%)
Please advise if it is possible to check a windows server drives while ignoring the c: drive.
Many thanks.
Command view
$USER1$/check_nrpe -H $HOSTADDRESS$ -c CheckDriveSize -a $ARG1$ $ARG2$ $ARG3$
Arg1= MaxWarn=10G
Arg2= MaxCrit=5G
Arg3= FilterType=Fixed CheckAllOthers Drive=C:
Based on the variety of information from Nagios and NSClient++ the above command should return the diskspace for all drives on a server excluding the c drive.
However, when testing the command from the web interface the below is returned:
COMMAND: /usr/local/nagios/libexec/check_nrpe -H <hostname> -c CheckDriveSize -a MaxWarn=10G MaxCrit=5G FilterType=FIXED CheckAllOthers Drive=C:
OUTPUT: CRITICAL C:: Total: 49.656GB - Used: 32.185GB (65%) - Free: 17.471GB (35%)|'C: used'=32.18547GB;10;5;0;49.65624 'C: used %'=64%;20;10;0;100
If I remove the Drive=C: we can see all drives:
COMMAND: /usr/local/nagios/libexec/check_nrpe -H htv440650 -c CheckDriveSize -a MaxWarn=10G MaxCrit=5G FilterType=FIXED CheckAllOthers
OUTPUT: CRITICAL C:\: Total: 49.656GB - Used: 32.186GB (65%) - Free: 17.47GB (35%), E:\: Total: 299.998GB - Used: 248.296GB (83%) - Free: 51.702GB (17%), F:\: Total: 599.873GB - Used: 297.601GB (50%) - Free: 302.272GB (50%), G:\: Total: 1.99TB - Used: 1.637TB (83%) - Free: 361.48GB (17%), H:\: Total: 1.221TB - Used: 970.921GB (78%) - Free: 278.951GB (22%), I:\: Total: 349.873GB - Used: 161.326GB (47%) - Free: 188.547GB (53%)
Please advise if it is possible to check a windows server drives while ignoring the c: drive.
Many thanks.