[collectd] Making monitoring of heterogeneous environments easier with percentage based metrics

Jeremy Katz katzj at fedoraproject.org
Wed Jan 8 01:47:25 CET 2014


In larger environments which have heterogeneous resources it's frequently
useful to look at utilization of various resources as percentages.  The df
plugin started to add this in 5.4 with the ReportAbsolute and
ReportPercentage options being added.  pyr then got the ball rolling on
adding percentages for memory and swap (
https://github.com/collectd/collectd/pull/501 and
https://github.com/collectd/collectd/pull/500) that I've also added a
second set of patches so that percentages get reported for all of the
values rather than just getting a percent used metric.

But all of these end up having a ton of repetition.  As I was working on
them and then starting to do the same for cpu utilization, it started to
leave something of a bad taste in my mouth.  I realized that we could do
something that would be more global similar to how StoreRates is available
in (most?) output plugins.    To get there, we could add a value_total to
value_list_t and then write plugins could use that to do a percentage
calculation if StorePercentages was set.  There would be a need to update
both output plugins and input plugins instead of just input plugins but I
think the changes would look a little cleaner.

Thoughts?

- Jeremy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.verplant.org/pipermail/collectd/attachments/20140107/4ea256d7/attachment.html>


More information about the collectd mailing list