Ad Widget

Collapse

Convert mib files to zabbix template ?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • aldms1126
    Junior Member
    • Sep 2021
    • 14

    #1

    Convert mib files to zabbix template ?

    Is it possible to convert the mib file to zabbix template?
    When I use mib2zabbix, it doesn't convert normally.
    The SNMP OID value appears normally when responding with snmpttranslate, but when piped to mib2zabbix, the template seems to be created referring to other mibs.

    When I read the mib file in snmpptTranslate,
    [root@mgmt_cdp Alteon]# snmptranslate -Tz -m ./ALTEON-CHEETAH-LAYER4-MIB.mib
    "org" "1.3"
    "dod" "1.3.6"
    "internet" "1.3.6.1"
    "directory" "1.3.6.1.1"
    "mgmt" "1.3.6.1.2"
    "experimental" "1.3.6.1.3"
    "private" "1.3.6.1.4"
    "enterprises" "1.3.6.1.4.1"
    "alteon" "1.3.6.1.4.1.1872"
    "registration" "1.3.6.1.4.1.1872.1"
    "aceswitch110" "1.3.6.1.4.1.1872.1.1"
    "acedirector" "1.3.6.1.4.1.1872.1.2"
    "aceswitch180" "1.3.6.1.4.1.1872.1.3"
    "acedirector2" "1.3.6.1.4.1.1872.1.4"
    "aceswitch180e" "1.3.6.1.4.1.1872.1.5"
    "acedirector3" "1.3.6.1.4.1.1872.1.6"
    "cachedirector" "1.3.6.1.4.1.1872.1.7"
    "gs-switches" "1.3.6.1.4.1.1872.1.8"
    "chas-switch" "1.3.6.1.4.1.1872.1.8.1"


    When the snmpttranslate data is piped into mib2zabbix,
    snmptranslate -Tz -m ./ALTEON-CHEETAH-LAYER4-MIB.mib | ./mib2zabbix -o .1.3.6.1.4.1 -f template-alteon_layer4-mib.xml -N Alteon_LAYER4-mib

    If you check the SNMP OID of template-alteon_layer4-mib.xml,
    <snmp_oid>.1.3.6.1.4.1.2021.16.2.1.101.{#SNMPINDEX }</snmp_oid>


    When responding with snmpttranslate,
    It normally responds with 1.3.6.1.4.1.1872.x, but if it is piped with mib2zabbix, it returns 1.3.6.1.4.1.2021.x. Is there a way to convert a template to a normal OID?
  • serkanbaybuga
    Junior Member
    • Jul 2022
    • 1

    #2
    Hello,

    Did you find the solution?

    Regards

    Comment


    • mk.hasan
      mk.hasan commented
      Editing a comment
      I am also getting same problem. Did you solve it ?
  • dimir
    Zabbix developer
    • Apr 2011
    • 1080

    #3
    You could try this one https://sbcode.net/zabbix/mib-to-zabbix-template/

    Comment

    • Yafimm
      Junior Member
      • May 2022
      • 9

      #4
      Yes, it is possible to convert a MIB file to a Zabbix template. MIB (Management Information Base) files contain definitions of objects that can be monitored by an SNMP (Simple Network Management Protocol) agent. Zabbix is a monitoring tool that can use SNMP to monitor devices on a network and display the collected data in the form of charts and graphs.

      To convert a MIB file to a Zabbix template, you can use a tool called mib2zabbix, which is a command-line tool that converts MIB files to Zabbix templates. However, if you are experiencing issues with mib2zabbix not converting the MIB file correctly, there are a few things you can try:
      1. Make sure you have the required dependencies installed: mib2zabbix requires Python and the PySNMP library to be installed on your system.
      2. Check the MIB file for errors: MIB files can be complex and may contain errors that prevent them from being parsed correctly by mib2zabbix. Use a MIB parser tool to check the MIB file for syntax errors and fix any issues you find.
      3. Use the -v option to increase the verbosity of the mib2zabbix output: This can help you identify any errors or issues that may be occurring during the conversion process.
      4. Make sure you have the correct MIBs installed: mib2zabbix may refer to other MIBs that are not installed on your system. In this case, you will need to find and install the missing MIBs in order for the conversion to be successful.

      If you are still having issues with mib2zabbix after trying these suggestions, you may want to consider using an alternative tool or method for converting MIB files to Zabbix templates. There are other tools and scripts available that may be able to help you with this task.

      Comment

      Working...