简体   繁体   中英

How to Extend SNMP Agent with Custom Bash Script, Custom Enterprise OID and Custom MIB

I am looking for a tutorial/guide to help me create a custom oid ( with my own enterprise number in the oid ), custom MIB using a variable base script in snmp Agent. Most of the examples I see on the Internet like

24.6.5. EXTENDING NET-SNMP

Tut:Extending snmpd using shell scripts

uses the method in which the result from the scripts are found in OIDs like .1.3.6.1.4.1.8072.*

which means if I run

$ snmpwalk -v2c -c testing 127.0.0.1 nsExtendOutput1
NET-SNMP-EXTEND-MIB::nsExtendOutput1Line."test" = STRING: hello
NET-SNMP-EXTEND-MIB::nsExtendOutputFull."test" = STRING: hello
NET-SNMP-EXTEND-MIB::nsExtendOutNumLines."test" = INTEGER: 1
NET-SNMP-EXTEND-MIB::nsExtendResult."test" = INTEGER: 0

what I want is the OID should include my custom Enterprise number. How to do this

So, After a lot of research, I came up with a detailed guide on how to achieve this. have a look at https://github.com/ahmednawazkhan/guides/blob/master/snmp/creating-custom-mib.md

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM