Status: Resolved (View Workflow)
Affects Version/s: 19.1.0, Meridian-2015.1.5
Component/s: Data Collection - SNMP
Security Level: Default (Default Security Scheme)
Any system with SNMP interface policies implementing DO_NOT_PERSIST behavior
Steps to reproduce on a freshly installed system:
1) Set the collectd appender to DEBUG or INFO in log4j2.xml
2) Edit default foreign-source definition, adding a Match SNMP Interface policy with action = DO_NOT_PERSIST and parameters that will match one interface on a node to be added. For example, key: ifDescr / value: eth1.
3) Use snmpwalk or a similar utility to determine the ifIndex of the interface targeted by this policy. On the system I'm using, it's 4.
4) Add node to system
Expected result: No log messages about data collected for the unpersisted interface, maybe?
Actual result: Lots of INFO-level messages indicating unable to locate resource for the unpersisted interface (instance id 4):
TBH I'm not sure there's anything inappropriate about logging these messages, because there's no way Collectd could (or even should) be aware of interfaces whose existence Provisiond has disavowed at the user's direction. The design of the SNMP collector makes it impossible to avoid getting the disavowed interfaces' data from the agent. Maybe the "fix" is to special-case the log message for resources of type ifIndex, adding a note that this behavior may be completely expected if DO_NOT_PERSIST policies are in use.