SNMP_Exporter Generator Cannot find oid

5,216 views
Skip to first unread message

Juan Escudero

unread,
Nov 17, 2017, 4:45:02 PM11/17/17
to Prometheus Users
Hi All,

Im getting the error below when i try to generate a new SNMP.yml file. I have the mibs in the correct location /usr/share/snmp/mibs.  I have also added my generator.yml file. 

when i run ./generator generate

INFO[0000] Loading MIBs from $HOME/.snmp/mibs:/usr/share/snmp/mibs  source="net_snmp.go:109"
WARN[0000] NetSNMP reported 1 parse errors               source="main.go:72"
INFO[0000] Generating config for module cisco_switches   source="main.go:30"
INFO[0000] Generated 41 metrics for module cisco_switches  source="main.go:33"
INFO[0000] Generating config for module if_mib           source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib        source="main.go:33"
INFO[0000] Generating config for module if_mib_ifalias   source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifalias  source="main.go:33"
INFO[0000] Generating config for module if_mib_ifdescr   source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifdescr  source="main.go:33"
INFO[0000] Generating config for module if_mib_ifname    source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifname  source="main.go:33"
INFO[0000] Generating config for module cisco_ucs        source="main.go:30"
FATA[0000] Cannot find oid '1.3.6.1.4.1.9.9.719.1.16' to walk  source="tree.go:155"



generator.yml


modules:
  # Default IF-MIB interfaces table with ifIndex.
  if_mib:
    walk: [sysUpTime, interfaces, ifXTable]
  # Interfaces if ifAlias is unique.
  if_mib_ifalias:
    walk: [sysUpTime, interfaces, ifXTable]
    lookups:
      - old_index: ifIndex
        new_index: ifAlias
  # Interfaces if ifDescr is unique.
  if_mib_ifdescr:
    walk: [sysUpTime, interfaces, ifXTable]
    lookups:
      - old_index: ifIndex
        new_index: ifDescr
  # Interfaces if ifName is unique.
  if_mib_ifname:
    walk: [sysUpTime, interfaces, ifXTable]
    lookups:
      - old_index: ifIndex
        # Use OID to avoid conflict with Netscaler NS-ROOT-MIB.
        new_index: 1.3.6.1.2.1.31.1.1.1.1 # ifName

# Cicso UCS
  cisco_ucs:
    walk:
      - interfaces
      - ifXTable
      - 1.3.6.1.4.1.9.9.719.1.16  #CISCO-UNIFIED-COMPUTING-ETHER-MIB
      - 1.3.6.1.4.1.9.9.719.1.3   #CISCO-UNIFIED-COMPUTING-ADAPTOR-MIB
      - 1.3.6.1.4.1.9.9.719.1.20  #CISCO-UNIFIED-COMPUTING-FC-MIB
      - 1.3.6.1.4.1.9.9.719.1.9   #CISCO-UNIFIED-COMPUTING-COMPUTE-MIB
      - 1.3.6.1.4.1.9.9.719.1.41  #CISCO-UNIFIED-COMPUTING-PROCESSOR-MIB
      - 1.3.6.1.4.1.9.9.719.1.15  #CISCO-UNIFIED-COMPUTING-EQUIPMENT-MIB
      - 1.3.6.1.4.1.9.9.719.1.30  #CISCO-UNIFIED-COMPUTING-MEMORY-MIB
      - 1.3.6.1.4.1.9.9.719.1.46  #CISCO-UNIFIED-COMPUTING-SW-MIB
    auth:
      community: xxxxx

# Cicso Switches
  cisco_switches:
    walk:
      - interfaces
      - ifXTable
      - 1.3.6.1.2.1.2
      - 1.3.6.1.2.1.31.1.1
#      - 1.3.6.1.4.1.14179.2.2.15.1.21  # bsnAPIfDBNoisePower
    auth:
      community: xxxxx

Thank you for your help in advance.


Brian Brazil

unread,
Nov 18, 2017, 3:11:26 AM11/18/17
to Juan Escudero, Prometheus Users
On 17 November 2017 at 21:45, Juan Escudero <juan.esc...@gmail.com> wrote:
Hi All,

Im getting the error below when i try to generate a new SNMP.yml file. I have the mibs in the correct location /usr/share/snmp/mibs.  I have also added my generator.yml file. 

when i run ./generator generate

INFO[0000] Loading MIBs from $HOME/.snmp/mibs:/usr/share/snmp/mibs  source="net_snmp.go:109"
WARN[0000] NetSNMP reported 1 parse errors               source="main.go:72"
INFO[0000] Generating config for module cisco_switches   source="main.go:30"
INFO[0000] Generated 41 metrics for module cisco_switches  source="main.go:33"
INFO[0000] Generating config for module if_mib           source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib        source="main.go:33"
INFO[0000] Generating config for module if_mib_ifalias   source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifalias  source="main.go:33"
INFO[0000] Generating config for module if_mib_ifdescr   source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifdescr  source="main.go:33"
INFO[0000] Generating config for module if_mib_ifname    source="main.go:30"
INFO[0000] Generated 42 metrics for module if_mib_ifname  source="main.go:33"
INFO[0000] Generating config for module cisco_ucs        source="main.go:30"

 
FATA[0000] Cannot find oid '1.3.6.1.4.1.9.9.719.1.16' to walk  source="tree.go:155"

You're missing the MIB with this object.

Brian
 

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscribe@googlegroups.com.
To post to this group, send email to prometheus-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/3539808c-48b9-4bbb-8026-3b9daaa4e155%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

Juan Escudero

unread,
Nov 20, 2017, 11:43:53 AM11/20/17
to Prometheus Users
I checked and i did not have the mib files so i uploaded them however i am still getting the same error.  Below are the MIB's and the error.  Do I need to convert the mibs that have .my extensioin.  

MIB's
-rw-r--r-- 1 root root  17K Jan 14  2016 CISCO-SMI.my
-rw-r--r-- 1 root root 101K Jun  9  2015 CISCO-TC.my
-rw-r--r-- 1 root root 2.8M Nov 17 16:30 CISCO-UNIFIED-COMPUTING-COMPUTE-MIB
-rw-r--r-- 1 root root 316K Oct  6 13:31 CISCO-UNIFIED-COMPUTING-ETHER-MIB.my
-rw-r--r-- 1 root root 1.5M Nov 17 16:31 CISCO-UNIFIED-COMPUTING-MIB
-rw-r--r-- 1 root root  66K Nov 17 16:31 CISCO-UNIFIED-COMPUTING-TC-MIB

Error
WARN[0000] NetSNMP reported 1923 parse errors            source="main.go:72"
INFO[0000] Generating config for module cisco_ucs        source="main.go:30"
FATA[0000] Cannot find oid '1.3.6.1.4.1.9.9.719.1.16' to walk  source="tree.go:155"

Benjamin Ritcey

unread,
Nov 20, 2017, 11:48:31 AM11/20/17
to Prometheus Users
Setting aside generator, see if NetSNMP can load the MIBs correctly;  try

snmptranslate -mALL 1.3.6.1.4.1.9.9.719.1.16

It should give you a full symbolic name

Juan Escudero

unread,
Nov 20, 2017, 12:05:20 PM11/20/17
to Prometheus Users
Thank you for the info.
I get the following now
Begining:

MIB search path: /root/.snmp/mibs:/usr/share/snmp/mibs
Cannot find module (CISCO-UNIFIED-COMPUTING-MIB): At line 49 in /usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my
Cannot find module (CISCO-UNIFIED-COMPUTING-TC-MIB): At line 124 in /usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my
Did not find 'ciscoUnifiedComputingMIBObjects' in module #-1 (/usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my)
Did not find 'CucsManagedObjectId' in module #-1 (/usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my)
Did not find 'CucsManagedObjectDn' in module #-1 (/usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my)

Middle:
Did not find 'CucsPortMode' in module #-1 (/usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my)
Did not find 'CucsPortapiPeerCapability' in module #-1 (/usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my)
Unlinked OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherObjects ::= { ciscoUnifiedComputingMIBObjects 16 }
Undefined identifier: ciscoUnifiedComputingMIBObjects near line 126 of /usr/share/snmp/mibs/CISCO-UNIFIED-COMPUTING-ETHER-MIB.my
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherFcoeInterfaceStatsHistEntry ::= { cucsEtherFcoeInterfaceStatsHistTable 1 }
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherPIoFsmRmtRslt ::= { cucsEtherPIoFsmEntry 11 }

End:
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherNiErrStatsHistTooShortDelta ::= { cucsEtherNiErrStatsHistEntry 30 }
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherNiErrStatsHistTooShortDeltaAvg ::= { cucsEtherNiErrStatsHistEntry 31 }
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherNiErrStatsHistTooShortDeltaMax ::= { cucsEtherNiErrStatsHistEntry 32 }
Cannot adopt OID in CISCO-UNIFIED-COMPUTING-ETHER-MIB: cucsEtherNiErrStatsHistTooShortDeltaMin ::= { cucsEtherNiErrStatsHistEntry 33 }
CISCO-SMI::ciscoMgmt.719.1.16

Benjamin Ritcey

unread,
Nov 20, 2017, 12:57:36 PM11/20/17
to Prometheus Users
There you go - you still need to track down some more MIBs - at least CISCO-UNIFIED-COMPUTING-MIB & CISCO-UNIFIED-COMPUTING-TC-MIB.


Repeat test with snmptranslate until it runs clean.

HTH,

-b

Benjamin Ritcey

unread,
Nov 20, 2017, 12:59:16 PM11/20/17
to Prometheus Users
Er, ignore me - you to appear to have those two - however, they're the two without the .my extensions.  I'd add the extensions.

Juan Escudero

unread,
Nov 20, 2017, 4:56:13 PM11/20/17
to Prometheus Users
i had tried before having them with .my, .txt, .oid and without an extension and none of them work

Benjamin Ritcey

unread,
Nov 21, 2017, 9:55:38 AM11/21/17
to Prometheus Users
Not sure where to point you then (maybe wrong line endings?  Try dos2unix on the files), but this isn't a Prometheus issue at this point - once snmptranslate is running correctly I think you'll be good with generator.

Juan Escudero

unread,
Nov 21, 2017, 2:23:35 PM11/21/17
to Prometheus Users
I got it working.  I just put all the cisco unified mibs in /usr/share/snmp/mibs and got it working.  I ran into an issue on the Fabric mib but i just took it out and its all working.
I will have to build the snmp.yml file a bit more specific with what i want to see since the new file was too large.  It went from 300k to 2.9M.  

Thanks again to all for your help

ee1

unread,
Dec 26, 2021, 9:18:04 PM12/26/21
to Prometheus Users
Thank you.  Had same issue.

With the Makefile from github, running 'make mibs' did download/extract the Cisco mibs, but placed them into ./mibs/cisco_v2/

I just copied all files to ./mibs and the generator ran successfully (so did snmptranslate).

Possibly another fix could have been specifying both directories in the "export MIBDIRS=..." step?

In any case, progress made.
Reply all
Reply to author
Forward
0 new messages