how to set warning disk usage alert between 89-90% as warning using snmp wizard for Linux/Unix servers.
We are using below commands for warning 89% and error 90%.
-C camops --v2c -m "^/var$" -w 89 -c 90 -f
how to set warning disk usage alert between 89-90% a warning
-
ganeshsambandam
- Posts: 62
- Joined: Mon Sep 10, 2018 1:52 pm
-
jforcier
Re: how to set warning disk usage alert between 89-90% a war
Code: Select all
-w @89:90More on thresholds and ranges:
https://nagios-plugins.org/doc/guidelin ... HOLDFORMAT
-
ganeshsambandam
- Posts: 62
- Joined: Mon Sep 10, 2018 1:52 pm
Re: how to set warning disk usage alert between 89-90% a war
Will @89:90 works for all the wizards like nrpe, NCPA etc?
-
ganeshsambandam
- Posts: 62
- Joined: Mon Sep 10, 2018 1:52 pm
Re: how to set warning disk usage alert between 89-90% a war
I'm getting an error when use that with snmp wizard, looks like it's not required for ncpa since it's doing calculation and giving output in decimal value. Please check and let me know the correct one to be used for snmp
./check_snmp_storage_wizard.pl -H 10.160.44.60 -C NAGIOS-SNMP --v2c -m "^/var$" -w @89:90 -c 90 -f
Argument "@89:90" isn't numeric in numeric lt (<) at ./check_snmp_storage_wizard.pl line 287.
/var: 76%used(4479MB/5920MB) (>@89:90%) : WARNING | '/var'=4479MB;0;5328;0;5920
./check_snmp_storage_wizard.pl -H 10.160.44.60 -C NAGIOS-SNMP --v2c -m "^/var$" -w @89:90 -c 90 -f
Argument "@89:90" isn't numeric in numeric lt (<) at ./check_snmp_storage_wizard.pl line 287.
/var: 76%used(4479MB/5920MB) (>@89:90%) : WARNING | '/var'=4479MB;0;5328;0;5920
Re: how to set warning disk usage alert between 89-90% a war
This particular plugin (check_snmp_storage_wizard.pl) takes only numeric values (integers), and doesn't follow the Nagios Plugins Development Guidelines in regards to thresholds.
From the plugin's usage (help) menu:
Isn't that what you wish to accomplish?
From the plugin's usage (help) menu:
Having said that, looking at your original post, using the "-w 89 -c 90" thresholds should give you exactly what you need... If the value is greater than 89 but less than (or equal to) 90, you would get a WARNING. If the value is greater than 90, you would get a CRITICAL.-w, --warn=INTEGER
percent / MB of disk used to generate WARNING state
you can add the % sign
-c, --critical=INTEGER
percent / MB of disk used to generate CRITICAL state
you can add the % sign
Isn't that what you wish to accomplish?
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
ganeshsambandam
- Posts: 62
- Joined: Mon Sep 10, 2018 1:52 pm
Re: how to set warning disk usage alert between 89-90% a war
actually the requirement is to have warning alert of the usage between 89 to 90 which means if the usage is 89% also should give an alert. So equal to 89% should have an alert for warning. Please suggest
Re: how to set warning disk usage alert between 89-90% a war
In this case, you could use "-w 88 -c 90".
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
ganeshsambandam
- Posts: 62
- Joined: Mon Sep 10, 2018 1:52 pm
Re: how to set warning disk usage alert between 89-90% a war
If i use "-w 88 -c 90". will alert creates if usage is 89.5% ?
Re: how to set warning disk usage alert between 89-90% a war
Yes, you will get a warning alert as 89.5% is higher than the warning threshold of 88, but it's lower than the critical threshold of 90. This is exactly what you said the requirement was:
actually the requirement is to have warning alert of the usage between 89 to 90 which means if the usage is 89% also should give an alert. So equal to 89% should have an alert for warning. Please suggest
Be sure to check out our Knowledgebase for helpful articles and solutions!