-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adaptive thresholds? #14
Comments
@joshbeard I am more than happy to think about it. Off-hand I see no problem with it as long as you can use the check without the thresholds, which it looks like you can. |
Correct. These additions don't change the default behavior at all. |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm curious what the thoughts are on providing "adaptive thresholds" for the percentages. For instance, 10% free of a 100GB volume is arguably more severe than 10% free of a 10TB volume. Adapting the thresholds based on volume size would allow for a single check to be more fitting of different volumes without triggering undesirable alerts.
This features is available in check_mk's disk check. I've forked the Sensu plugin here and added this functionality in if anyone would like to take a look and consider it:
https://github.com/sensu-plugins/sensu-plugins-disk-checks/compare/master...joshbeard:adaptive?expand=1
The idea is that you provide base percentages for warning and critical thresholds. These percentages are slightly adjusted for larger filesystems based on a "magic factor" the user can provide. A magic factor of 0 (the default) does no adjustment at all (current behavior). There's also an option to modify the normalized factor, where volumes of exactly that size will not be adjusted. Finally, there's an option to specify a minimum size to adjust, so volumes smaller than this will not be adapted.
This can be visualized with WolframAlpha with something like the following:
Where P = base percentage, N = normalize factor, and m = magic factor
The text was updated successfully, but these errors were encountered: