Cisco Works, SNMP, MIBs.
New Member
Wed Feb 10, 2010 12:23 pm

Problem with snmptt, snmpttconvertmib and Cisco MIBs

Thu Jun 28, 2012 3:56 am

Hello everyone!

As the title says (kind of) I have a problem with converting Cisco MIBs to a readable format for snmptt.

At the moment, I have a almost working environment with Nagios Core receiving SNMP traps, and presenting them in the web GUI. I've managed to convert some MIB-files (IF-MIB), and therefore I can see when an interface on my 3560-switch changes state to up or down.

However, I also have a Cisco PGW2200, which I would like to monitor using SNMP traps. The problem is that when I try to convert the MIB files for that product, I end up with only a few converted MIBs. I can see that my Nagios-machine receive the traps (in syslog), but without any translation happening, which means that Nagios fails to present them i the Web-GUI. What I think is that there must be more information in my unconverted MIB-files that I can extract.

The MIB files for the PGW can be found here: (9.7)

I understand that some MIB files depend on others, and that it wont work without every needed MIB file. The thing I do is that I take a MIB file, and all the MIB files stated in the IMPORT field in that certain MIB, put them in a folder (/usr/share/snmp/mibs/pgw) export that folder as MIBDIR. I then use a for loop to convert all the MIB files. In the end I just see the following message "The MIB file did not contain any TRAP-TYPE or NOTIFICATION-TYPE definitions, so no translation occurred." No other error messages is presented.

I can see in the file that there is no lines that include TRAP-TYPE or NOTIFICATION-TYPE, however, I can see that there is a lot of fields that contain OBJECT-TYPE. Isn't that a field that can be converted?

If I, for a start, would like to convert the (can be found with the link above), I read the IMPORT-part at the beginning of the file, and add the MIB files required. In the end I have the following files:,,, RFC1155-SMI.mib, RFC1158-MIB.mib, RFC1212.mib,,,,

I put them in /usr/share/snmp/mibs/pgw and add that folder to MIBDIRS with the following command:
# export MIBDIRS=/usr/share/snmp/mibs:/usr/share/snmp/mibs/pgw

With a for loop I go through the files and try to convert them to snmptt-format
# for i in pgw/*
> do
> snmpttconvertmib --format_desc=6 --in=$i --out=/etc/snmp/ --exec='/usr/local/nagios/libexec/eventhandlers/submit_check_result $r TRAP 1' 2>>errors
> done

This is as far as I get with the conversion. No error messages is received.

Any ideas?

Thank you

Wed Aug 19, 2009 7:22 pm

Re: Problem with snmptt, snmpttconvertmib and Cisco MIBs

Thu Jun 28, 2012 8:33 am

If there are no Notifications in the .my file and there is no associated .traps file then this mib is for polling only and no snmp traps are sent to nms.
There are 10 types of people in the world. Those who understand binary and those who don't.

New Member
Wed Feb 10, 2010 12:23 pm

Re: Problem with snmptt, snmpttconvertmib and Cisco MIBs

Thu Jul 05, 2012 7:48 am

Thanks for explaining! Makes me feel kind of dumb though, heh.

However, my problem seemed to be that one of the MIB-dependencies were broken. After some manual modifying of that file, it worked, but I'm not quite sure that this is the recommended solution.

I think that it seems kind of unlikely that a MIB-file from Cisco is broken.



Return to Cisco Network Management

Who is online

Users browsing this forum: No registered users and 9 guests