[collectd] Plugins for postfix, amavisd-new and powerdns
collectd at c-ware.com
Mon Mar 31 20:43:17 CEST 2008
Florian Forster wrote:
> Hi Luke,
> sorry that it took so long, but I finally got around to set up a virtual
> host and install PowerDNS there. I'm currently trying to fit the
> recursor statistics into something reasonable.
> The statistics I could make sense out of are:
the counters are briefly documented at
http://downloads.powerdns.com/documentation/pdns.pdf starting on pages
119 and 139. (Actual page numbers, subtract 8 for the page number as
displayed in the pdf itself.)
> Number of answers/replies by RCODE, i. e. number of answers that were
> successful, didn't exist or the server failed.
> Milliseconds spent in system/user mode.
> Overall latency.
> Cache hits/misses.
> Now a long list of values remain. I'd like to know which values are
> actually interesting and which I should ignore. For instance:
> Answers by time it took answer them. I don't think that's very
> interesting, but that's just a wild guess..
a spike in slow answers might be an event you'd want to see in a graph.
> Number of entries in the cache. Not sure if that's interesting. Might
> be, since the recursor is basically all about the cache - right? What
> about `negcache-entries'?
the negcache is a cache of "negative" answers. i.e. nxdomain, server
timeout, etc. It's nice that it's a separate cache because a spike here
would indicate that we're getting dns errors on a lot of different
records. Not at all useful though if the caching of negative answers
is disabled in the config file.
> Overall number of questions. Surely interesting, but it's somehow
> unspecific. Aren't there some more detailed counters available?
> Queries by query type would be nice, for example.
Unfortunately, no. However if this becomes available in a future
version then the plugin should be able to handle it without any changes.
> And so on.. Can you help me deciding what goes in and what is ignored
> (or rather dropped from the query)?
That's really a matter of personal preference, which is why I made
it configurable. One may set the command used by the plugin in it's
configuration to get only the counters that you would like. That's
documented in the doc.diff patch from the original email.
the rec_control and pdns_control commands installed with powerdns offer
the same counters via a command line interface. For example, the
command line "rec_control get user-msec sys-msec" will print those two
counters and the command line "pdns_control show \*" will print all
counters and the command line "pdns_control show corrupt-packets will
print that counter. Unfortunately both the command line and the plugin
are limited by the protocol exposed by powerdns, namely:
- the wildcard syntax is supported only by pdns_control.
- retrieval of multiple specific counters is supported only by rec_control.
To illustrate this, the command line
"pdns_control show corrupt-packets deferred-cache-inserts" is invalid and
will display an error. The only way to get multiple counters is to get them
all with the wildcard.
And the command line "rec_control get \*" will attempt to get the counter
literally named "*" and return an UNKNOWN value. The only way to get all
counters is to actually ask for them all as in the default query in
HTH. Let me know if I can be of any assistance.
More information about the collectd