[collectd] Patch: Swap usage percentage
ssevertson at digitalmeasures.com
Wed Jun 6 21:16:19 CEST 2012
From a threshold/notification perspective, we find it useful to set
values based on percentages. Specifically, we'd like to set thresholds
on the percent of swap space in use, rather than on absolute kilobyte
I've attached a patch that adds a "percent" metric to swap.c for all
currently enabled code paths. I've only verified functionality on
Solaris 10, but the changes were pretty straight forward for all
supported data sources. I did attempt to make my changes in the style of
the surrounding function
Ironically, I didn't touch the disabled Solaris 10 libkstat code, as the
comments indicated it belonged in vmem.c in the long term...
Please let me know if anyone tries out this patch and experiences
compilation or operational problems.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3655 bytes
Desc: not available
More information about the collectd