Ad Widget

Collapse

How do I troubleshoot: SNMP OID problem?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • cconstantine
    Junior Member
    • Sep 2013
    • 4

    #1

    How do I troubleshoot: SNMP OID problem?

    I have a host where the SNMP "box" under the Availability column is red. The associated error is "Error building ASN.1 representation (Can't build OID for variable)."
    I've seen a few other no-responses threads with this problem, so I'm looking for a way to dig into this to figure out the underlying problem(s).

    How do I troubleshoot what is wrong, or missing?

    Is there an error log somewhere?
    ...or a way to enable error logging of SNMP work?
    Can I figure out if I'm missing a MIB?
    ...or MIBs are installed in the wrong place?
    ...Zabbix server configured without SNMP support?
    etc...

    version info

    Zabbix 2.0.9
    Ubuntu 12.04LTS
    PHP 5.3.10
    PHP's NET-SNMP version is 5.4.3
  • aib
    Senior Member
    • Jan 2014
    • 1615

    #2
    Hi, cconstantine!

    Did you try to use command
    Code:
    grep SNMP /var/log/zabbix/zabbix_server.log | more
    If you need some DEBUG information, you can set DebugLevel to highest level 4 (temporarily, because it generate a lot of lines in your zabbix_server.log file)

    Code:
    # vi /etc/init.d/zabbix_server.conf
    ......
    DebugLevel=4
    ......
    After changing DebugLevel, restart Zabbix server and try to catch SNMP information about your host

    Code:
    tail -f /var/log/zabbix/zabbix_server.log | grep SNMP | grep {your_host_name}
    When you fix the problem don't forget to switch DebugLevel back to 3 (or 0) to save your log file from infinite growth.
    Sincerely yours,
    Aleksey

    Comment

    • cconstantine
      Junior Member
      • Sep 2013
      • 4

      #3
      thanks!

      Thanks for the helpful directions into debug logging!

      I changed the debug level and restarted. Still didn't see any SNMP related errors... lots of debug logging though.

      And then I realized the SNMP "block" was now enabled/green. I recently installed some snmp packages on the system, and I must have failed to restart the Zabbix server.

      Comment

      • aib
        Senior Member
        • Jan 2014
        • 1615

        #4
        I glad to hear that your problem fixed!
        Sincerely yours,
        Aleksey

        Comment

        • lpic.lt
          Junior Member
          • Sep 2014
          • 6

          #5
          Hi ALL!

          I have the same problem.

          I have loaded new MIB's to a dir, and now snmpget gets the value, but zabbix still receives errors:

          Code:
          snmp_build: unknown failure 24203:20150409:123701.339 SNMP item [memActiveReal] on host [HostName2] failed: first network error, wait for 60 seconds
          snmp_build: unknown failuresnmp_build: unknown failure 24197:20150409:123732.661 SNMP item [fwInstallTime] on host [HostName1] failed: first network error, wait for 60 seconds
          snmp_build: unknown failure 24323:20150409:123801.081 resuming SNMP checks on host [HostName2]: connection restored
          snmp_build: unknown failure 24193:20150409:123802.392 SNMP item [tunnelState[vpn_point_Name]] on host [HostName2] failed: first network error, wait for 60 seconds
          snmp_build: unknown failure 24322:20150409:123832.089 resuming SNMP checks on host [HostName1]: connection restored
          snmp_build: unknown failure 24317:20150409:123902.093 resuming SNMP checks on host [HostName2]: connection restored
          snmp_build: unknown failure 24194:20150409:123903.339 SNMP item [memTotalReal] on host [HostName2] failed: first network error, wait for 60 seconds
          [B]snmp_build: unknown failuresnmp_build: unknown failure[/B] 24225:20150409:123934.236 SNMP item [fwNumConn] on host [HostName1] failed: first network error, wait for 60 seconds
          snmp_build: unknown failure 24327:20150409:124003.106 resuming SNMP checks on host [HostName2]: connection restored
          snmp_build: unknown failure 24259:20150409:124005.224 SNMP item [tunnelState[vpn_Names]] on host [HostName2] failed: first network error, wait for 60 seconds
          [B]snmp_build: unknown failuresnmp_build: unknown failure[/B] 24324:20150409:124034.115 SNMP item [haProblemStatus[Filter]] on host [HostName1] failed: another network error, wait for 60 seconds
          snmp_build: unknown failure 24318:20150409:124105.117 resuming SNMP checks on host [HostName2]: connection restored
          snmp_build: unknown failure 24323:20150409:124134.128 resuming SNMP checks on host [HostName1]: connection restored
          snmp_build: unknown failure 24213:20150409:124137.687 SNMP item [haProblemStatus[cphad]] on host [HostName2] failed: first network error, wait for 60 seconds
          snmp_build: unknown failuresnmp_build: unknown failure 24257:20150409:124153.582 SNMP item [tunnelState[vpn_point_Newy]] on host [HostName1] failed: first network error, wait for 60 seconds
          snmp_build: unknown failure 24321:20150409:124237.140 resuming SNMP checks on host [HostName2]: connection restored
          snmp_build: unknown failure 24323:20150409:124253.143 resuming SNMP checks on host [HostName1]: connection restored
          mean while, SNMPwalk goes through it... BUT, it hangs for a while and drops me timeout:
          Code:
          .1.3.6.1.4.1.2620.1.1.27.1.11.16.0 = ""
          Timeout: No Response from HOST_IP
          When I o snmpwalk over "system info" or some specific section, it returns without any error... Also, when I do SNMPGET with exact MIB value (text or number) it is ok, but if snmpwalk, so itreturns me value + error:
          Code:
          Error: OID not increasing...
          I think it is good... so problem, is that it gets timeout... is it on OS level or somewhere on zabbix server conf file?

          Comment

          • lpic.lt
            Junior Member
            • Sep 2014
            • 6

            #6
            Hi ALL!

            I have some interesting findings...

            tcpdump do NOT see any requests to that host... But LOG says SNMP requests were sent...

            iptables -L -n show, that NO rules are set and ALL chains are with policy ACCEPT...

            Comment

            • lpic.lt
              Junior Member
              • Sep 2014
              • 6

              #7
              One more interesting thing, when I have changed MIB to OID, I have received SNMP reply... So one more time, do I need to restart zabbix after a MIB file addition? Or I can do it without restart?

              Comment

              • aquarios
                Junior Member
                • May 2021
                • 4

                #8

                You can force the "-Cc" option of the SNMPwalk to be applied globally (for all user) - including Zabbix the following way:
                Code:
                printf "dontCheckOrdering 1\n" | sudo tee /etc/snmp/snmpwalk.conf
                Also check the "Max repetition count" setting on the host's interface level to prevent the output from being truncated

                Comment

                Working...