Hello,
I have been working on generating a snmp.yml config for my UCS Central box. I have successfully pulled some information and got it working, but now I am looking at improving it. I am using a "conversation" from 2018 that looks promising. However, I am running into an error about not finding metrics in main.plain. I see that "metrics" has maybe been phased out, at least in the way it was used here. You will also see I am getting a "Can't find augmenting node", I have not been able to find much on that error, however my configs will generate if that is the only error. Please see below for my generator config and the error(s) that I got. Thanks in advance!
Config:
modules:
# Default IF-MIB interfaces table with ifIndex.
if_mib_if_name:
walk: [sysUpTime, interfaces, ifXTable]
lookups:
- source_indexes: [ifIndex]
lookup: ifAlias
- source_indexes: [ifIndex]
# Uis OID to avoid conflict with PaloAlto PAN-COMMON-MIB.
lookup: 1.3.6.1.2.1.2.2.1.2 # ifDescr
- source_indexes: [ifIndex]
# Use OID to avoid conflict with Netscaler NS-ROOT-MIB.
lookup: 1.3.6.1.2.1.31.1.1.1.1 # ifName
overrides:
ifAlias:
ignore: true # Lookup metric
ifDescr:
ignore: true # Lookup metric
ifName:
ignore: true # Lookup metric
ifType:
type: EnumAsInfo
auth:
community: ***
cisco_ucs:
walk:
- 1.3.6.1.4.1.9.9.719.1.1.1.1.16
- 1.3.6.1.4.1.9.9.719.1.1.1.1.2
metrics:
- name: cucsFaultOccur
oid: 1.3.6.1.4.1.9.9.719.1.1.1.1.16
type: counter
help: Cisco UCS fault:Inst:occur managed object property - 1.3.6.1.4.1.9.9.719.1.1.1.1.16
indexes:
- labelname: cucsFaultDn
type: gauge
- labelname: cucsFaultTags
type: OctetString
lookups:
- labels:
- cucsFaultDn
labelname: cucsFaultDn
oid: 1.3.6.1.4.1.9.9.719.1.1.1.1.2
type: DisplayString
- labels:
- cucsFaultTags
labelname: cucsFaultTags
oid: 1.3.6.1.4.1.9.9.719.1.1.1.1.21
type: OctetString
version: 2
auth:
community: ***
Errors:
ts=2023-05-16T19:05:24.910Z caller=net_snmp.go:161 level=info msg="Loading MIBs" from=/etc/snmp_exporter_generator/generator/mibs/
ts=2023-05-16T19:05:27.567Z caller=main.go:119 level=warn msg="NetSNMP reported parse error(s)" errors=1
ts=2023-05-16T19:05:28.302Z caller=tree.go:83 level=warn msg="Can't find augmenting node" augments=portCopyEntry node=portCopyXEntry
ts=2023-05-16T19:05:28.325Z caller=main.go:129 level=error msg="Error generating config netsnmp" err="error parsing yml config: yaml: unmarshal errors:\n line 31: field metrics not found in type main.plain"