-
Notifications
You must be signed in to change notification settings - Fork 1
mib2opennms rm repository
License
xrmx/mib2opennms
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
------------------------------------------------------------------------------- - mib2opennms - - Author: Tomas Carlsson <tc@tompa.nu> - - http://tompa.nu/mib2opennms - - $Id$ ------------------------------------------------------------------------------- This utility can read data from a collection of SNMP MIBs and output all the NOTIFICATION-TYPEs in OpenNMS eventconf.xml format. It depends on libsmi (http://www.ibr.cs.tu-bs.de/projects/libsmi/), packages libsmi2 and libsmi2-dev on Debian. BUILD ----- To compile run configure and make from the top level directory: $ ./configure $ make install To change the default install location (/usr/local) add the "-prefix=<path>" argument when running configure. RUNNING ------- To run: $ mib2opennms -f outputfile -m <MIB path list> MIB1 MIB2 ... for example: > mib2opennms -f myfile.xml -m ~/.snmp/mibs:/usr/share/snmp/mibs \ CISCO-CCM-MIB CISCO-WIRELESS-IF-MIB Note that the MIB path must include the paths where all mentioned MIBs and their imported MIBs can be found. The MIBs to convert can either be given as MIB module names or filenames, i.e the following command is possible: > mib2opennms -f myfile.xml -m ~/.snmp/mibs:/usr/share/snmp/mibs \ ~/.snmp/mibs/CISCO-* and will convert all MIB files that starts with CISCO-. The output file is not a complete xml file but only <event> entries that can be pasted into eventconf.xml. The output looks like this: <event> <mask> <maskelement> <mename>id</mename> <mevalue>.1.3.6.1.4.1.9.9.136.2.3.1</mevalue> </maskelement> </mask> <uei>http://uei.opennms.org/traps/cwrTrapThresh</uei> <event-label>cwrTrapThresh</event-label> <descr> <pre> The radio subsystem generates this trap when a threshold crosses its specified limit. The parameters identify the following cwrThreshValue - The value that was crossed. cwrThreshHysteresisTime - The Hysteresis time that was specified. cwrThreshLimitTime - The Limit time that was specified. </pre> cwrThreshValue=%parm[1]%<br> cwrThreshHysteresisTime=%parm[2]%<br> cwrThreshLimitTime=%parm[3]%<br> </descr> <logmsg dest='logndisplay'> cwrTrapThresh trap received </logmsg> <severity>Indeterminate</severity> </event> SOME NOTES (added by Tarus): ---------------------------- If mib2opennms complains about a missing MIB, be sure that there is a file in your "-m" MIB path that has the *exact* name as the MIB it is complaining about. For example, if it complains "Can't find RFC-1213" and you have a file in your path called "RFC1213", you must rename it or copy it to "RFC-1213". The extensions .txt, .my and I believe .mib are acceptable, so in the above example, RFC-1213.txt should work. Also, the <mevalue> for generic should almost always be "6", although mib2opennms usually sets it to "0".
About
mib2opennms rm repository
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published