[collectd] syntax to collect snmpd 'extend' script results ?

Florian Forster octo at verplant.org
Mon Jul 6 14:22:19 CEST 2009


On Tue, Jun 30, 2009 at 04:17:22PM -0400, L. Gabriel Somlo wrote:
> I have a bunch of scripts running on a server, each returning a
> current count of some value, which increments over time.
> I've added the following to my /etc/snmp/snmpd.conf:

good science! [0] Why would you do that? It'd be probably much more
elegant to let the `exec' plugin [1] handle that.

> I would like to collect these with collectd via snmp, and here's
> what's in my /etc/collectd.d/snmp.conf file:

Could you provide an SNMP-walk for those trees please?

>    <Data "host_load">
>       Type "host_load"
>       Table false
>       Values "UCD-SNMP-MIB::laLoadInt.1" "UCD-SNMP-MIB::laLoadInt.2" "UCD-SNMP-MIB::laLoadInt.3"
>    </Data>

> 	snmp plugin: DataSet `host_load' not defined

This happens because collectd doesn't know how the data is structured.
It tries to find out by looking up the `host_load' “type” which doesn't
exist. Please see the types.db(5) manual page for a description of how
to add a custom type. The `TypesDB' option in collectd.conf(5) may be of
interest, too.

>    <Data "host_extend">
>       Type "host_dns"
>       Table true
>       Values "NET-SNMP-EXTEND-MIB::nsExtendOutput2Table"
>    </Data>

`host_dns' isn't a standard type, either, you will have to define that,

> and complete silence on host_extend...

This shouldn't be.. Can you resolve the OID-name without extra arguments
using `snmptranslate'? Maybe the tree can be fetched but not
interpreted? Can you maybe use tcpdump or wireshark to see if some
communication between collectd and snmpd takes place?


[0] I hope there are some SouthPark fans out there ;)
[1] <http://collectd.org/wiki/index.php/Plugin:Exec>
Florian octo Forster
Hacker in training
GnuPG: 0x91523C3D
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mailman.verplant.org/pipermail/collectd/attachments/20090706/5508de3f/attachment.pgp 

More information about the collectd mailing list