Home » Other »Handy SNMP OIDs

SNMP OIDs Worth Having

SNMP is much loathed by most of my colleagues, but it can be quite handy for determining system information. For example - I recently encountered a firmware issue with the NICs on certain HP ProLiant servers. In order to tell what version of the firmware was on each network card, there were slightly different procedures for ESX/Linux and Windows. On ESX or Linux, you can run ethtool -i. On Windows, you need to look at the HP Systems Management Homepage. However, in all cases it is possible to retrieve that information using SNMP. Run snmpwalk and query for the OID and ye shall be greeted with something like this:
iso. = STRING: "4.0.556"
iso. = STRING: "4.0.556"
Which tells me that the firmware version on each interface is 4.0.556.


The basic syntax for SNMPWalk (on Linux or Windows) is:
snmpwalk -t timeout -r retries -v version -c communitystring destination OID
The -t option says how long SNMPWalk should wait for a respsonse. Around 5 seconds seems to be a sane value.
The -r option says how many retries SNMPWalk should make if it fails to get the data the first time. I usually set this to 0.
The -v version defines which version of SNMP you want to use. Unless there's a good reason otherwise, I tend to set this to 2c.
The -c option is your SNMP community string. Many (most?) devices have a default string of public. You'll have to check your environment's SNMP configuration in order to tell which value you need to use.
The destination is the hostname or IP address of the device/computer you wish to interrogate. You'll need to be sure that the device/computer is configured to listen for SNMP traffic on the IP address you're talking to it on.
The OID is the bit which tells the remote SNMP daemon/service which information you're interested in. Which OIDs are available will depend on the type of device/computer you're talking to, and which MIBs are installed on it.
If SNMPWalk isn't working for you, you should check the following:

That said, here's the list of SNMP OIDs, which I'll add to over time:

Generic OIDs

HP/Compaq ProLiant OIDs