title: How to get OIDs from a MIB file?
body: <p>I want to read all the objects from the MIB file that a manager has. </p>
  
  <p>I developed one tool to get some data from a SNMP enabled agent. I want to enhance that tool by showing all the OIDs form the manager's MIB file. </p>
  
  <p>I am using the NET-SNMP library.</p>
  
  <p>I saw the following:</p>
  
  <pre><code>/usr/local/share/snmp/mibs/ 
  </code></pre>
  
  <p>folder and it contains many MIB files, but how can I form a list of the OIDs it has?</p>
  
  <p>I went through the MIBs and saw the structures, but how do I get the OIDs of each and every object mentioned in the MIB files? </p>
  
  <p>I want to list all the OIDs as follows:</p>
  
  <ol>
  <li><code>SNMPv2-MIB::sysDescr.0  = .1.3.6.1.2.1.1.1.0</code></li>
  <li><code>SNMPv2-MIB::sysObjectID.0 =  .1.3.6.1.2.1.1.2.0</code>
  ... etc</li>
  </ol>
  
  <p>I want to scan all the MIB files and find all the OIDs from the files.</p>
  
  <p>How do I do this?</p>