generator.yml
root@exporter:~/snmp_exporter/generator# cat generator.yml 
---
# The generator config format version.
version: 2

auths:
  public_v1:
    version: 1
  public_v2:
    version: 2

modules:
  # Default IF-MIB interfaces table with ifIndex.
  cisco:
    #walk: [sysUpTime, interfaces, ifXTable,ciscoMemoryPoolUsed]
   # walk:  
    walk:
      - sysDescr
      - sysUpTime
      - sysName
      - interfaces
      - ifXTable
     # - cpmCPUTotalTable
     # - cieIfPacketStatsEntry
      - 1.3.6.1.2.1.2.2.1.1
      - 1.3.6.1.2.1.2.2.1.2
      - 1.3.6.1.2.1.2.2.1.10
      - 1.3.6.1.2.1.2.2.1.13
      - 1.3.6.1.2.1.2.2.1.14
      - 1.3.6.1.2.1.2.2.1.16
      - 1.3.6.1.2.1.2.2.1.19
      - 1.3.6.1.2.1.2.2.1.2
      - 1.3.6.1.2.1.2.2.1.20
      - 1.3.6.1.2.1.2.2.1.5
      - 1.3.6.1.2.1.2.2.1.7
      - 1.3.6.1.2.1.2.2.1.8
      - 1.3.6.1.2.1.31.1.1.1.1
      - 1.3.6.1.2.1.31.1.1.1.18
     # - 1.3.6.1.4.1.9.9.48.1.1.1.5
     # - 1.3.6.1.4.1.9.9.48.1.1.1.6
     # - 1.3.6.1.4.1.9.2.1
      - 1.3.6.1.2.1.1.5
      - 1.3.6.1.4.1.9.9.48.1.2
     # - 1.3.6.1.4.1.9.9.109.1.1 # Defined within Cisco private mib 
CISCO-PROCESS-MIB
    lookups:
      - source_indexes: [ifIndex]
        lookup: ifAlias
      - source_indexes: [ifIndex]
        lookup: ifDescr
      - source_indexes: [ifIndex]
        lookup: 1.3.6.1.2.1.31.1.1.1.1 # ifName
   # 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

mibs folder path & Mibs 

root@exporter:~/snmp_exporter/generator# cd /usr/share/snmp/
root@exporter:/usr/share/snmp# ls
mib2c-data  mibs  mibs-downloader  snmpconf-data  snmp_perl.pl
root@exporter:/usr/share/snmp# cd mibs
root@exporter:/usr/share/snmp/mibs# ls
*CISCO-MEMORY-POOL-MIB.text*  NET-SNMP-EXAMPLES-MIB.txt         
NET-SNMP-VACM-MIB.txt   UCD-DISKIO-MIB.txt
*CISCO-PROCESS-MIB.text*      NET-SNMP-EXTEND-MIB.txt           
SNMP-COMMUNITY-MIB      UCD-DLMOD-MIB.txt
GNOME-SMI.txt               NET-SNMP-MIB.txt                 
 SNMP-FRAMEWORK-MIB      UCD-IPFILTER-MIB.txt
iana                        NET-SNMP-MONITOR-MIB.txt         
 SNMP-IEEE802-TM-MIB     UCD-IPFWACC-MIB.txt
ietf                        NET-SNMP-PASS-MIB.txt             
SNMP-NOTIFICATION-MIB   UCD-SNMP-MIB-OLD.txt
IF-MIB                      NET-SNMP-PERIODIC-NOTIFY-MIB.txt  SNMP-TSM-MIB 
           UCD-SNMP-MIB.txt
LM-SENSORS-MIB.txt          NET-SNMP-SYSTEM-MIB.txt           
SNMP-USER-BASED-SM-MIB
NET-SNMP-AGENT-MIB.txt      NET-SNMP-TC.txt                   
UCD-DEMO-MIB.txt


On Saturday, July 22, 2023 at 4:16:29 PM UTC+5:30 Hemedi Salim wrote:

> If you can break down how you are generating the snmp.yml. 
> But Is like the you are missing the actual MIB file/OID in the directory 
> you are generating from. 
>
>
>
>
> On Fri 21 Jul 2023 at 15:22, 'Abhiraj Verma' via Prometheus Users <
> [email protected]> wrote:
>
>>
>> Getting this error white generating snmp.yml
>>
>>
>> ts=2023-07-19T15:55:45.342Z caller=main.go:136 level=error msg="Error 
>> generating config netsnmp" err="cannot find oid '1.3.6.1.4.1.9.9.109.1.1' 
>> to walk"
>>
>> make: *** [Makefile:70: generate] Error 1
>>
>>
>>
>> Disclaimer: This e-mail and any files transmitted with it are 
>> confidential and intended solely for the use of the individual or entity to 
>> whom they are addressed. If you are not the intended addressee, or the 
>> person responsible for delivering it to them, you may not copy, forward 
>> disclose or otherwise use it or any part of it in any way. To do so may be 
>> unlawful. If you receive this e-mail by mistake, please advise the sender 
>> immediately.
>>
>>
>> -- 
>> 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 [email protected].
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/prometheus-users/4f319c78-6c34-4042-877f-282dea527744n%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/prometheus-users/4f319c78-6c34-4042-877f-282dea527744n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>
-- 




Disclaimer: This e-mail and any files transmitted with it are 
confidential and intended solely for the use of the individual or entity to 
whom they are addressed. If you are not the intended addressee, or the 
person responsible for delivering it to them, you may not copy, forward 
disclose or otherwise use it or any part of it in any way. To do so may be 
unlawful. If you receive this e-mail by mistake, please advise the sender 
immediately.

-- 

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/689dc4cb-52cf-4ff9-86f7-260242b14ccfn%40googlegroups.com.

Reply via email to