Difference between revisions of "FAQ:MIBs 03"

From Net-SNMP Wiki
Jump to: navigation, search
(Move FAQ text to a template page & 5.4 release synchronisation)
(Latest FAQ revision - preparing for 5.5 release)
Line 1: Line 1:
= I'm getting answers, but they're all numbers. Why? =
+
= Where should I put my MIB files? =
  
 
<!-- NB:
 
<!-- NB:
Line 7: Line 7:
 
   MIBs section.
 
   MIBs section.
 
  -->
 
  -->
{{FAQ:MIBs_04}}
+
{{FAQ:MIBs_03b}}
  
 
     [[FAQ:MIBs]]
 
     [[FAQ:MIBs]]
 
     {{FAQ:MIBs}}
 
     {{FAQ:MIBs}}

Revision as of 12:12, 28 May 2009

Where should I put my MIB files?

If you've compiled the package from source (or are using binaries from the project website), then you should probably put new MIB files in the directory /usr/local/share/snmp/mibs

If you are using vendor-supplied binaries, then the MIB files may well be located somewhere else (e.g. /usr/share/snmp/mibs, /opt/snmp/mibs, or /etc/sma/snmp/mibs). Have a look for where existing MIB files are installed, and try adding your MIBs to the same directory.

If you compiled the source yourself, but specified a different --prefix value when running configure, then the location of the MIB directory will be {prefix}/share/snmp/mibs.

If you're still not sure where to put your MIB files, try running the command

    snmpget  -Dparse-mibs  2>&1 | grep directory

This will display the location(s) where the library is looking for MIB files.

   FAQ:MIBs
   
  1. Where can I find a MIB compiler?
  2. Why aren't my MIB files being read in?
  3. Where should I put my MIB files?
  4. What does "Cannot find module (XXX-MIB)" mean?
  5. I'm getting answers, but they're all numbers. Why?
  6. What does "unlinked OID" mean?
  7. The parser doesn't handle comments properly. Why not?
  8. How can I get more information about problems with MIB files?
  9. What's this about "too many imported symbols"?
  10. Do I actually need the MIB files?