[collectd] how to collect string values with snmp plugin

Niels Tomey niels at ixs.ph
Mon Feb 29 08:58:12 CET 2016


I would like to have collectd parse text values such as those found in
'system' (sysName, sysContact, sysLocation and so on). While researching it
seems that alphanumerical strings should be of the 'octet' type, however
there doesn't appear to be a suitable DataSet in
/usr/share/collectd/types.db by default.

I can hardly imagine I'm the first one who wants to do this, but I can't
find anything on the subject online so I might be looking completely wrong
at this subject.

When using snmpwalk I see the values I want to store, but when I ask
collectd to get these values like so:

<Data "sysName">
                Type "absolute"
                Table false
                Instance "SNMPv2-MIB"
                Values "sysName"
        </Data>

I can see in the log file that collectd gets the proper result, but doesn't
know what to do with it.

[2016-02-29 14:53:10] parse_value: Failed to parse string as absolute:
(null).
[2016-02-29 14:53:10] snmp plugin: csnmp_value_list_to_value: Parsing
string as absolute failed: *hostname1*
[2016-02-29 14:53:10] parse_value: Failed to parse string as absolute:
(null).
[2016-02-29 14:53:10] snmp plugin: csnmp_value_list_to_value: Parsing
string as absolute failed: *hostname2*

Do I need to define a custom data type for this, or is there something else
I should do to get these results?

Kind regards,

Niels
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.verplant.org/pipermail/collectd/attachments/20160229/924ec7bb/attachment.html>


More information about the collectd mailing list