e3e6fa4f1d
In many default installations ceph and varnish binaries require root permissions or specific user permissions to actually gather metrics. Although it's possible to instrumented system configuration to either run telegraf with root privileges or share the same user/permissions as measured software it's not a default setup. In my opinion ability to run binary with `sudo` makes entire setup simpler without additional interaction. My changes allow to use configuration like: ``` binary = "/usr/bin/sudo /usr/bin/varnishstat" ceph_binary = "/usr/bin/sudo /usr/bin/ceph" ``` With a proper sudo configuration it will simplify amount of changes needed to collect metrics. I've also changed type of varnish metrics. It was `int` but in varnish source code we can find all metrics are actually uint64 (https://github.com/varnishcache/varnish-cache/blob/master/include/tbl/vsc_f_main.h) I hit that issue with some metrics: ``` ~# varnishstat -1 | grep -i MAIN.n_objectcore MAIN.n_objectcore 18446744073709550877 . objectcore structs made ``` |
||
---|---|---|
.. | ||
inputs | ||
outputs | ||
parsers | ||
serializers |