How to Parse SNMP MIB Files to generate a list of Devices and OID | Parse MIB to CSV {easy way 2021}

In this post, I will show you the easiest way to parse SNMP MIB files to generate a list of Devices and OID in CSV format. Recently, for one of the assignment, I was needing a list of NetApp OID's and events to share with the team to schedule storage alerts.

There was no proper documentation available online, so I decided to write a step by step guide to achieve it. So that nobody else need to struggle like I did.

I will show you the whole procedure with the NetApp MIB file but the process will be applicable to all MIBs whether it is of Dell-EMC, Broadcom, Cisco or any vendor.

What is MIB

MIB stands for Management information base. It is a text file that describes Traps and SNMP Objects. The file contains entries in tree-structure (hierarchical) format and each entry is referenced as Object Identifier (OID). Each OID identifies a variable that can be read by using SNMP. Where SNMP stands for Simple Network Management Protocol.

For example, Below mentioned image shows NetApp MIB OIDs structure -

MIB-file-details

Requirements to Parse SNMP MIB browser

To parse SNMP MIB of any Technology vendor like Dell EMC, NetApp or HP. You would need these three things -

  1. SNMP MIB browser with capability to export it to CSV or XML
  2. SNMP MIB file from vendor support site
  3. Software to open the exported CSV file. e.g. MS excel or Open office calc.

Download free SNMP mib browser

To download free SNMP MIB browser, follow these simple steps -

Step1.1 - Visit ireasoning.com and Download SNMP MIB browser for free

  • Open your favourite browser and visit ireasoning.com.
  • Click on the "Download Now" button on the home page.
MIB-browser-download-site
  • Once you will reach the software download page. Click on "Download" against MIB browser free personal edition.
  • Accept MIB browser license agreement (Personal edition)
Download-free-mib-browser

The free personal edition offers limited features, but enough for our purpose of parsing MIB to CSV format. In case you want to explore all features of the MIB browser. You can download the Professional or Enterprise edition of the MIB browser. It's free to evaluate for 30 days.

  • Click on setup.exe for Windows and You will get this in your download folder.
Download-snmp-mib-browser-free-for-windows

How to Parse SNMP MIB Files to generate a list of Devices and OID

I am assuming that you have already downloaded the required MIB file and MIB browser software at this point.

In case you are looking for a NetApp MIB file, you can download it from the NetApp support website. You would need a NetApp username and password to log in. Else you can leave a comment, I will arrange it for you.

Follow along to parse SNMP MIB files to generate a list of OIDs -

Step2.1- Install free SNMP browser first

To read and parse MIB file to CSV, you need an SNMP browser. To install SNMP Browser, Double click on setup.exe, which you have downloaded in the last section.

Run-setup-to-install-mib-browser

Step2.2- Accept user access control permission

Select "Yes", when it prompts to allow this app to make changes.

Accept-UAC

Step2.3- Accept End User License Agreement (EULA)

On this screen, just click "I Agree" to accept MIB browser license agreement.

Accept-EULA

Step2.4- Choose features of MIB Browser

Once you will accept the license agreement and you will reach on next screen. You will get the option to choose the components or features of the MIB browser you want to install.

There are two components available as shown in image -

  1. MIB Browser - It is a required or mandatory component. You can't deselect it. Reason?? Don't you want to install SNMP Browser? 😉
  2. Start Menu and Desktop Icon - Selecting this option will create Menu and Desktop shortcut icons for MIB browser software. So totally your choice, if you want to create these icons or not.

The space required to install SNMP Browser is approx. 130.6 MB. So make sure you have enough disk space available in your system.

I will suggest to keep both option selected and Hit Next button.

Select-MIB-Browser-components

Step2.5- Choose Installation location for SNMP MIB Browser

On this screen, You need to select the installation location of the SNMP Browser. The default location would be "C:\Program files (x86)\ireasoning\mibbrowser\" as shown in the image. If you wish to select a custom location, Just <Click> on the Browse button and choose the different destination folder.

I will go with default installation directory.

Click Install.

Select-SNMP-MIB-browser-installation-location

Step2.6- Wait for SNMP MIB browser setup to complete

Now the installation of the SNMP MIB browser will start. It will take only a few minutes to complete. You can click on the show details button to check what all files are getting extracted.

Installing-MIB-browser

Select Close button, once setup completes.

Step2.7- Launch MIB Browser

Once you will close setup wizard, it will ask you to "Launch MIB Browser". Just Select "Yes".

MIB-browser-installation-completed

Step2.8- Extract your NetApp MIB files

All SNMP MIB files are always in Zip format. Once you download them from your vendor website. In the case of NetApp, it has two levels of compression.

For example, Once you will unzip the NetApp MIB file. It will have two more files, NetApp.mib.Z and traps.dat.Z inside. These are Unix compressed files.

You can download WinRAR software, in case you are unable to extract the ".Z" extension file in Windows 10.

So with reference to the image -

  1. First I extracted the NetApp_mib_2_13 zip file and I got two files inside it.
  2. I extracted NetApp.mib archive file
  3. Found NetApp.mib file, that is ready to upload to the browser.

Same process goes for traps.dat file, if you need it.

Extract-NetApp-MIB-file

Step2.9- Load NetApp.mib file to SNMP Browser

Now switch to the SNMP Mib browser window. Select File > Load MIBs. Alternatively, you can press <Ctrl + L> on your keyboard.

Browse to the location, where you have extracted your SNMP MIB file. Select and It will Load the MIB file to the iReasoning MIB browser.

Load-MIB-file-to-snmp-browser

Step2.10- Validate the MIB modules

Once you will load the MIBs, just cross-check they are loaded as shown in the image. If not try again. Ignore the mgmt modules in the MIB tree. These are the default ones already present in the browser.

validate-MIB-modules

Step2.11- Export SNMP MIB to CSV

Now you just need to <Right click> on either NetApp or root of the MIB tree i.e. "iso.org.dod.internet" and choose the Export to CSV option.

export-mib-to-csv-format

Step2.12- Save the ".csv" file and open it with MS Excel

Save the CSV file with your preferred name. Then open it with MS excel.

Apply filter and select NetApp-MIB to see the list of devices and OIDs of NetApp MIB Modules. If you need this NetApp Mib CSV file, click here.

parse-snmp-mib-to-csv

That all, we are done with procedure of parsing SNMP mib to csv format.

Video Tutorial

If you have any doubt while following this tutorial. Just check out this useful video on "How to parse SNMP Mib files to .csv".

Parse SNMP Mib file to excel

Summary

I hope you will find this tutorial useful and your struggle to convert MIB to CSV will end here. You can leave your comments, in case you have any difficulty parsing any MIB file. I will try my best to help you.

See you soon in the next post.. Till that time Happy Learning!!