Page 1 of 1
check_drivesize not accepting warn and crit values
Posted: Thu May 02, 2019 5:31 am
by nfbnbm
Hi guys or girls,
Nobody is answering in Git and thought I might try to receive an answer here.
https://github.com/mickem/nscp/issues/611
In short, warn and crit filter are always overwritten with default 80% and 90%.
Am I missing something?
Thanks in advance.
Re: check_drivesize not accepting warn and crit values
Posted: Thu May 02, 2019 3:09 pm
by scottwilkerson
We have some example syntax here
https://support.nagios.com/kb/article/d ... s-770.html
I looked at your github post and it seems you are grouping parts of the command with quoted around it
Instead of this
Code: Select all
alias_disk = check_drivesize "perf-config=*(unit:g) warning=used>90% critical=used>95% filter=removable=1 and type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
maybe try this
Code: Select all
alias_disk = check_drivesize 'warning=used>90%' 'critical=used>95%' 'perf-config=*(unit:G)' "filter=removable=1 and type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
Re: check_drivesize not accepting warn and crit values
Posted: Fri May 03, 2019 1:54 am
by nfbnbm
scottwilkerson wrote:We have some example syntax here
https://support.nagios.com/kb/article/d ... s-770.html
I looked at your github post and it seems you are grouping parts of the command with quoted around it
Instead of this
Code: Select all
alias_disk = check_drivesize "perf-config=*(unit:g) warning=used>90% critical=used>95% filter=removable=1 and type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
maybe try this
Code: Select all
alias_disk = check_drivesize 'warning=used>90%' 'critical=used>95%' 'perf-config=*(unit:G)' "filter=removable=1 and type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
Hi and thanks for responding!
Your command does not work. Status information:
Code: Select all
Invalid command line: unrecognised option ''warning=used>90%''
When changing the command from 'command' to "command":
Code: Select all
check_drivesize "warning=used>90%" "critical=used>95%" "perf-config=*(unit:G)" "filter=removable=1 and type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
Status information:
Any other ideas?
Re: check_drivesize not accepting warn and crit values
Posted: Fri May 03, 2019 7:45 am
by scottwilkerson
I was going off of your Github issue post where you had
filter=removable=1
this means it will only show removable drives....
try this
Code: Select all
alias_disk = check_drivesize 'warning=used>90%' 'critical=used>95%' 'perf-config=*(unit:G)' "filter=type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
Re: check_drivesize not accepting warn and crit values
Posted: Mon May 06, 2019 1:18 am
by nfbnbm
scottwilkerson wrote:I was going off of your Github issue post where you had
filter=removable=1
this means it will only show removable drives....
try this
Code: Select all
alias_disk = check_drivesize 'warning=used>90%' 'critical=used>95%' 'perf-config=*(unit:G)' "filter=type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
That did the trick. Many thanks Scott.
Re: check_drivesize not accepting warn and crit values
Posted: Mon May 06, 2019 6:56 am
by scottwilkerson
nfbnbm wrote:scottwilkerson wrote:I was going off of your Github issue post where you had
filter=removable=1
this means it will only show removable drives....
try this
Code: Select all
alias_disk = check_drivesize 'warning=used>90%' 'critical=used>95%' 'perf-config=*(unit:G)' "filter=type in ('fixed')" drive=all-drives show-all exclude=A: exclude=D:
That did the trick. Many thanks Scott.
Great!
Glad it's working
Locking thread