Archived community.zenoss.org | full text search
Skip navigation
60380 Views 7 Replies Latest reply: Nov 17, 2009 9:46 AM by bautistaj RSS
akiefer Newbie 2 posts since
Oct 31, 2008
Currently Being Moderated

Oct 31, 2008 11:25 AM

Add Mibs

I am trying to add MIBS for a Cisco 3560 or OID Mapping. If I want to add mibs, what is the default directory that they should be added? I have been looking through the documentation on mib directory and how to make zenoss make use of the new mibs. Can anyone give a quick and dirty?
  • guyverix ZenossMaster 846 posts since
    Jul 10, 2007
    Currently Being Moderated
    1. Oct 31, 2008 1:49 PM (in response to akiefer)
    RE: Add Mibs
    This is going to be VERY buggy, but it will give you an idea on how to do this.

    as zenoss user:

    /usr/local/zenoss/zenoss/bin/zenmib run --path=/usr/local/zenoss/common/share/mibs/site/*


    put your mibs /usr/local/zenoss/common/share/mibs/site/


    I had a lot of trouble getting mine installed, but this is one of the ways that I got some installed. When you get failures for missing mib XXX dependency, load that one before your cisco mib..
  • dbuck Rank: Green Belt 119 posts since
    Jul 22, 2008
    Currently Being Moderated
    2. Nov 3, 2008 4:26 AM (in response to guyverix)
    this will help
    Hello akiefer,

    there are some things recommended:

    1. search the path under /zenoss/ where /share/ and /libexec/ are
    Example /usr/zenoss/common/share/ /usr/zenoss/common/libexec/

    make symbolic link to this path in path ZENHOME$, because in older Version they where in ZENHOME$. Group and owner should be user:zenoss

    2. add an enviroment variable with all full paths to mibs in file
    .bashrc or .profile in $ZENHOME

    Example:

    export SMIPATH=$ZENHOME/share/mibs:$ZENHOME/share/mibs/iana:$ZENHOME/share/mibs/ietf:$ZENHOME/share/mibs/irtf:$ZENHOME/share/mibs/site:$ZENHOME/share/mibs/tubs



    3. search your MIB-File for line "IMPORTS"
    when there lines begin with "xxxxxxxx FROM yyyyy-MIB"
    these lines are dependencies MIB-files

    sometimes the name of the MIB-file depend from the MIB-Name shown in MIB itself

    Example:

    A3COM0004-GENERIC DEFINITIONS ::= BEGIN
    
    
         IMPORTS
              generic FROM A3Com-products-MIB
              OBJECT-TYPE FROM RFC-1212


    The first Line is the Name of the MIB "A3COM0004-GENERIC" (zenmib-command is case-sensitiv!!!) but the MIB-file is named "3COM0004.MIB".

    After "IMPORTS" there are two dependencies-MIB

    first: "A3Com-products-MIB" wich is 3Com special an must be first in line of zenmib-command (see example below)

    second: "RFC-1212" wich is in the $ZENHOME/share/mibs/ietf - path and included automatically (see below)

    compare the dependencies-MIB-files to MIB-files in path $ZENHOME/share/mibs/iana, ..../mibs/ietf, ..../mibs/irtf, ..../mibs/tubs (not ..../mibs/site, this directory is for your device-special MIBs)
    MIBs in these paths are include automatically

    4. copy MIB-File and the device-special-dependence MIB-files to $ZENHOME/share/mibs/site

    specific dependence MIBs must be first in same line of zenmib-command
    its a little bit like a chain ...
    when dependence MIB-files Import special MIB-files they must be first in line of zenmib-command.

    in the example below the mib-dependence-a1-MIB is in chapter "IMPORTS" line "FROM" of second MIB-file mib-dependence-1-MIB, wich is in "IMPORTS"-chapter of MIB-file mib-dependence-2-MIB, wich is in "IMPORTS"-chapter of MIB-file cisco-MIB

    Example with two dependencies with one "subdependence":

    as user zenoss in zenconsole in path $ZENHOME type

    zenmib -run ./share/mibs/site/mib-dependence-a1-MIB ./share/mibs/site/mib-dependence-1-MIB ./share/mibs/site/mib-dependence-2-MIB ./share/mibs/site/cisco-MIB (or whatever the name of the MIB-Files are)
    


    Hope it will helpful
  • dbuck Rank: Green Belt 119 posts since
    Jul 22, 2008
    Currently Being Moderated
    3. Nov 3, 2008 4:36 AM (in response to dbuck)
    this will help2
    Hello akiefer,


    an Addition to my post:

    I renamed all my MIB-files in $ZENHOME/share/mibs/site with the original MIB-Name inside.

    Example:

    3COM0004.MIB to A3Com-products-MIB.

    It's easier to use dependencies in zenmib-command-line

    I delete all Remark-Lines before the MIB-Name in the MIB-file because sometimes the zenmib-command read special words like FROM in Remark-Lines and then reply errors of missing dependencies
  • bautistaj Rank: White Belt 83 posts since
    Nov 11, 2009
    Currently Being Moderated
    5. Nov 16, 2009 5:12 PM (in response to akiefer)
    Re: RE: this will help2

    This procedure to add MIBs for other devices works with Zenoss 2.5??

     

    Thanks

     

    Jose

  • dbuck Rank: Green Belt 119 posts since
    Jul 22, 2008
    Currently Being Moderated
    6. Nov 16, 2009 6:01 PM (in response to bautistaj)
    Re: RE: this will help2

    Hi bautistaj,

     

    it should be working in 2.5 too, but I'm not test it, because I haven't a new MIB-File to import yet. But the following links are Helpful:

     

    docs/DOC-2445#HowdoIloadMIBs

     

    docs/DOC-2450

     

    And Helpfull for searching OID's in installed MIB-Files in Zenoss is this ZenPack:

     

    docs/DOC-3412

     

    Greetings

     

    dbuck

  • bautistaj Rank: White Belt 83 posts since
    Nov 11, 2009
    Currently Being Moderated
    7. Nov 17, 2009 9:46 AM (in response to dbuck)
    Re: RE: this will help2

    Thanks dbuck!

     

    Jose

More Like This

  • Retrieving data ...