FAQ:MIBs 03
Why aren't my mib files being read in?
The Net-SNMP library only loads a subset of MIB files by default. This list is set at when the suite is first configured and compiled, and basically corresponds to the list of modules that the agent supports. (This is a simplification, but is a reasonable first approximation).
You can override this by using the command-line option '-m', the
environmental variable 'MIBS'
or the
snmp.conf
directive 'mibs'
.
Each of these take a (colon-separated) list of MIB module names
to load. Starting the list with a '+' character will add them to
the default list - otherwise it replaces the defaults.
Using the special value 'ALL' will load all the MIB files that the library can find.
Alternatively, the tools may be looking in the wrong place.
The default location for the mib files is /usr/local/share/snmp/mibs
.
Again, this is set when the suite is first configured and compiled.
This can be changed using the environmental variable 'MIBDIRS'
or the snmp.conf
directive 'mibdirs'
.
Note that this may very well affect you if you've installed a new version of the suite manually, replacing one provided by the supplier (which typically would use a more 'central' location).
Finally, are you sure that you've installed the MIB files?
If you've compiled the suite from scratch, you need to run
"make install"
at least once, before the tools will be able to
find the MIB files. This is unlikely to be a problem if you've
been working with the tools for a while, but can bite those coming
fresh to the SNMP world.
FAQ:MIBs
- Where can I find a MIB compiler?
- Why aren't my MIB files being read in?
- Where should I put my MIB files?
- What does "Cannot find module (XXX-MIB)" mean?
- I'm getting answers, but they're all numbers. Why?
- What does "unlinked OID" mean?
- The parser doesn't handle comments properly. Why not?
- How can I get more information about problems with MIB files?
- What's this about "too many imported symbols"?
- Do I actually need the MIB files?