Ad Widget

Collapse

SNMP Builder for Zabbix

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sire
    Senior Member
    • Jul 2010
    • 210

    #256
    Originally posted by chrisransley
    Hi,

    Is there a patch for v1.8.13

    Code:
    The text leading up to this was:
    --------------------------
    |diff -Nur zabbix-1.8.12.orig/frontends/php/include/locales/ru_ru.inc.php zabbix-1.8.12/frontends/php/include/locales/ru_ru.inc.php
    |--- zabbix-1.8.12.orig/frontends/php/include/locales/ru_ru.inc.php     2012-04-13 10:40:35.000000000 +0400
    |+++ zabbix-1.8.12/frontends/php/include/locales/ru_ru.inc.php  2012-04-11 17:15:19.000000000 +0400
    --------------------------
    File to patch: /var/www/html/zabbix/include/locales/en_gb.inc.php
    patching file /var/www/html/zabbix/include/locales/en_gb.inc.php
    Hunk #1 FAILED at 2150.
    1 out of 1 hunk FAILED -- saving rejects to file /var/www/html/zabbix/include/locales/en_gb.inc.php.rej
    can't find file to patch at input line 62
    Perhaps you used the wrong -p or --strip option?
    Did you try this recipe? http://www.zabbix.com/forum/showpost...&postcount=238
    Regards,
    Sergey Syreskin

    Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

    Temporary out of Zabbix business

    Comment

    • chrisransley
      Junior Member
      • May 2012
      • 5

      #257
      Hi,

      When I access the file using vi or other text editors I get incorrect characters.

      PHP Code:

      +// SNMP Builder
      +       'S_SNMP_BUILDER' => 'Ã<98>üÿþÃ<80>Ã<82> SNMP MIB',
      +        
      'S_NO_HOST_ADDR' => 'Ã<9d>õ Ã<83>úð÷ðý Ã°Ã´Ã<80>õÃ<81> Ã<83>÷ûð Ã<81>õÃ<82>ø',
      +        
      'S_INVALID_HOST_ADDR' => 'Ã<9d>õôþÿÃ<83>Ã<81>Ã<82>øüÃ<8b>ù Ã°Ã´Ã<80>õÃ<81> Ã<83>÷ûð Ã<81>õÃ<82>ø',
      +       
      'S_OID_LIST_IS_NULL' => 'áÿøÃ<81>þú OID Ã¿Ã<83>Ã<81>Ã<82>',
      +       
      'S_OID_IS_NULL' => 'OID Ã¿Ã<83>Ã<81>Ã<82>',
      +       
      'S_INVALID_TYPE' => 'Ã<9d>õôþÿÃ<83>Ã<81>Ã<82>øüÃ<8b>ù Ã<82>øÿ',
      +       
      'S_OID_TREE' => 'Ã<94>õÃ<80>õòþ OID',
      +       
      'S_OID_DATA' => 'Ã<94>ðýýÃ<8b>õ OID',
      +       
      'S_CLICK_TO_FORCE_VIEW_AS_TABLE' => 'Ã<9f>Ã<80>øýÃ<83>ôøÃ<82>õûÃ<8c>ýþ Ã¿Ã<80>õôÃ<81>Ã<82>ðòøÃ<82>Ã<8c> Ã² Ã²Ã¸Ã´Ãµ Ã<82>ðñûøÃ<86>Ã<8b>',
      +       
      'S_OID_NAME' => 'OID/Ã<98>üÃ<8f>',
      +       
      'S_DELTA' => 'Ã<94>õûÃ<8c>Ã<82>ð'

      Comment

      • chrisransley
        Junior Member
        • May 2012
        • 5

        #258
        Ok... got this to work.

        Got a problem when attempting to upload a MIB file though. I get:

        Code:
        Command: cp -f /tmp/php200n4u /usr/share/snmp/mibs/v762b3.mib. 
        
        Message: cp: cannot create regular file `/usr/share/snmp/mibs/v762b3.mib': Permission denied

        Comment

        • sire
          Senior Member
          • Jul 2010
          • 210

          #259
          Originally posted by chrisransley
          Ok... got this to work.

          Got a problem when attempting to upload a MIB file though. I get:

          Code:
          Command: cp -f /tmp/php200n4u /usr/share/snmp/mibs/v762b3.mib. 
          
          Message: cp: cannot create regular file `/usr/share/snmp/mibs/v762b3.mib': Permission denied
          Regards,
          Sergey Syreskin

          Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

          Temporary out of Zabbix business

          Comment

          • sire
            Senior Member
            • Jul 2010
            • 210

            #260
            Muca,

            what is the location of SNMP MIBs on your system, is it the same as specified in snmp_builder.php?
            Regards,
            Sergey Syreskin

            Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

            Temporary out of Zabbix business

            Comment

            • sire
              Senior Member
              • Jul 2010
              • 210

              #261
              Muca,

              Fix MIBS_ALL_PATH in snmp_builder.php to match your MIBs location.
              Regards,
              Sergey Syreskin

              Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

              Temporary out of Zabbix business

              Comment

              • sire
                Senior Member
                • Jul 2010
                • 210

                #262
                Originally posted by Muca
                Sire,
                I have already done that?
                It may be some JavaScript error. Are there any errors in the Apache log?
                Regards,
                Sergey Syreskin

                Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

                Temporary out of Zabbix business

                Comment

                • chrisransley
                  Junior Member
                  • May 2012
                  • 5

                  #263
                  H,

                  Upgraded to Zabbix 2.0 and installed SNMP builder script for v2.0. This is working apart from the fact that there are no images being displayed. No matter were I put the imgs folder.

                  In v2.0 were do the imgs go?

                  Comment

                  • sire
                    Senior Member
                    • Jul 2010
                    • 210

                    #264
                    Originally posted by chrisransley
                    H,

                    Upgraded to Zabbix 2.0 and installed SNMP builder script for v2.0. This is working apart from the fact that there are no images being displayed. No matter were I put the imgs folder.

                    In v2.0 were do the imgs go?
                    In 2.0 images go to zabbix/js/jquery/themes/mib/
                    Regards,
                    Sergey Syreskin

                    Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

                    Temporary out of Zabbix business

                    Comment

                    • chrisransley
                      Junior Member
                      • May 2012
                      • 5

                      #265
                      Hi,

                      I managed.

                      I place all image files in "js/jquery/themes/mib/" folder.

                      Comment

                      • atimonin
                        Junior Member
                        • Jun 2012
                        • 10

                        #266
                        Sire, (and maybe some others)

                        Great job! Thanks!

                        I've made some chane to snmpbuilder to make a more unerstandable
                        description for zabbix item (only for interfaces: ifTable - ifDescr).
                        Now it looks like (for Cisco in my case):

                        Click image for larger version

Name:	snmpbuilder-2.png
Views:	1
Size:	102.2 KB
ID:	309891

                        You may see ifDescr as zabbix item description? which is much more useful to me than oid + ifindex (especially for a large number of interfaces)

                        The only difference is in snmp_builder.php (see attachment)
                        It may be simpy done for other tables or oids, but I can't figure what ones and what to use as description...

                        Comment

                        • sire
                          Senior Member
                          • Jul 2010
                          • 210

                          #267
                          Originally posted by atimonin
                          Sire, (and maybe some others)

                          Great job! Thanks!

                          I've made some chane to snmpbuilder to make a more unerstandable
                          description for zabbix item (only for interfaces: ifTable - ifDescr).
                          Now it looks like (for Cisco in my case):

                          [ATTACH]4812[/ATTACH]

                          You may see ifDescr as zabbix item description? which is much more useful to me than oid + ifindex (especially for a large number of interfaces)

                          The only difference is in snmp_builder.php (see attachment)
                          It may be simpy done for other tables or oids, but I can't figure what ones and what to use as description...
                          Hi atimonin,

                          I also considered this feature, but think of a situation when ifDescr changes. Item description will no more represent the corresponding interface.
                          Regards,
                          Sergey Syreskin

                          Monitored hosts: 2646 / Active items: 23604 / Server performance: 765.74

                          Temporary out of Zabbix business

                          Comment

                          • atimonin
                            Junior Member
                            • Jun 2012
                            • 10

                            #268
                            Originally posted by sire
                            Hi atimonin,

                            I also considered this feature, but think of a situation when ifDescr changes. Item description will no more represent the corresponding interface.
                            Yes, possible. Also possible that even ifIndex changes (for ex. after conf change), but in all the case if I see ifDescr in item it's simplier to me to understand what's going on.

                            Comment

                            • frlan
                              Junior Member
                              • May 2012
                              • 18

                              #269
                              Any chance to get it into default distribution?

                              Comment

                              • atimonin
                                Junior Member
                                • Jun 2012
                                • 10

                                #270
                                Originally posted by frlan
                                Any chance to get it into default distribution?
                                You mean zabbix distibution or snmpbuilder on jithub?

                                Comment

                                Working...