Ad Widget

Collapse

can´t receive snmp traps from the hosts

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gerardmr
    Junior Member
    • Oct 2008
    • 8

    #1

    can´t receive snmp traps from the hosts

    when we use snmpwalk, we only see traps received from 161 port but We can see all traps using wireshark sniffer program.

    the questions are:

    1) There is any place where we have to configure the port to receive traps?
    2) We need a mib file to zabbix program understand traps that its receiving?

    note: the traps we receive aren't standards traps likes servers traps or routers traps, etc.


    Please help me as soon as possible...
  • troffasky
    Senior Member
    • Jul 2008
    • 567

    #2
    SNMP trap port is 162. I've never seen SNMP traps with snmpwalk. You use the 'walker to see what OIDs an agent supports for polling. Polling and trapping are completely independent of each other, as far as I know.

    Comment

    • gerardmr
      Junior Member
      • Oct 2008
      • 8

      #3
      Originally posted by troffasky
      SNMP trap port is 162. I've never seen SNMP traps with snmpwalk. You use the 'walker to see what OIDs an agent supports for polling. Polling and trapping are completely independent of each other, as far as I know.
      Ok! Thanks. So which steps did you follow to install a SNMP Agent or to read a specific MIB tree?

      Comment

      • troffasky
        Senior Member
        • Jul 2008
        • 567

        #4
        Are we talking about polling or trapping now?

        Comment

        • gerardmr
          Junior Member
          • Oct 2008
          • 8

          #5
          Originally posted by troffasky
          Are we talking about polling or trapping now?
          Just trapping.
          I need read a few snmp traps.

          Comment

          • troffasky
            Senior Member
            • Jul 2008
            • 567

            #6
            Have you followed this?:

            http://www.zabbix.com/wiki/doku.php?id=howto:snmptraps

            Comment

            • gerardmr
              Junior Member
              • Oct 2008
              • 8

              #7
              I'm running Zabbix v1.4 with Ubuntu v8.04.
              I neet a Configuration NetSNMP Traps Server to Ubuntu.
              Do you have some additional suggest?

              Thanks so much!!

              Comment

              • richlv
                Senior Member
                Zabbix Certified Trainer
                Zabbix Certified SpecialistZabbix Certified Professional
                • Oct 2005
                • 3112

                #8
                you use snmptrapd to receive and pass traps to zabbix. it listens, as already mentioned, on port 162. (latest zabbix version is 1.6.2, hmm, coincidence )
                did you see the howto ? while it wasn't too generic, it should provide some hints.
                Zabbix 3.0 Network Monitoring book

                Comment

                • MrKen
                  Senior Member
                  • Oct 2008
                  • 652

                  #9
                  Originally posted by gerardmr
                  the questions are:

                  1) There is any place where we have to configure the port to receive traps?
                  2) We need a mib file to zabbix program understand traps that its receiving?
                  1. On your ZabbixTrap Host you will use Port 10051, so it can receive the traps from the Zabbix Sender.
                  On the snmp side of things, snmp will always default to Ports 161/162, so they really don't need to be touched.

                  2. MIBs need to be installed in the ..../snmp/mibs directory and then referenced in snmp.conf

                  A good place to learn more about snmp is : http://www.net-snmp.org/wiki/index.php/Tutorials


                  Personally, I find that the standard Zabbix Trap script doesn't provide the information that I want in a readable form, so I recently installed snmptt (http://www.snmptt.org/ ).

                  snmptt acts as the trap handler, translates the traps using the MIBs that you installed, and sends the trap to Zabbix using Zabbix Sender. See the end of this link for how to 'snmptt to zabbix sender' http://www.brentrjones.com/

                  btw - Google tells me that snmptt works on Ubuntu

                  MrKen
                  Disclaimer: All of the above is pure speculation.

                  Comment

                  • louis
                    Junior Member
                    • Dec 2009
                    • 2

                    #10
                    trapping in Zabbix

                    Hello Guys,

                    I'm a bit confused. I don't know to use the trapping in Zabbix 1.6.7.
                    Someone can help me.
                    Thanks for answers.

                    Comment

                    • MrKen
                      Senior Member
                      • Oct 2008
                      • 652

                      #11
                      Hi louis,

                      The zabbix manual is reasonably clear on setting up snmptraps. Section 4.18.2 around p.137.

                      On your zabbix server you need to find snmptrap.sh and put the IP address of the zabbix server, and the correct path to zabbix_sender. You will see KEY="snmptraps"; and HOST="snmptraps"; - this means you will need to create a new host called snmptraps and an item for that host called snmptraps.

                      You also need to edit snmptrapd.conf and add:
                      traphandle default /bin/bash /path/to/zabbix/sbin/snmptrap.sh

                      Don't forget to start snmptrapd.

                      Failing that, try the various links posted above.

                      MrKen
                      Disclaimer: All of the above is pure speculation.

                      Comment

                      • oct
                        Junior Member
                        • Dec 2009
                        • 22

                        #12
                        SNMPTT traps bind to different hosts

                        Hi MrKen

                        I've already configured net-snmp, snmptt and zabbix to receive snmp traps to a fake host as described on http://www.brentrjones.com/?p=13

                        My question now is: is it possible to bind traps to different hosts? It would be good to have a list of traps associated to each monitored host. I found a guide (http://pierky.wordpress.com/2009/01/...he-right-host/) for doing it if I use snmptrap.sh, but this script does not work very well in Ubuntu.

                        Thanks for your help

                        Oct

                        Comment

                        • richlv
                          Senior Member
                          Zabbix Certified Trainer
                          Zabbix Certified SpecialistZabbix Certified Professional
                          • Oct 2005
                          • 3112

                          #13
                          it's possible, but depends on the solution you use and what your requirements are. i don't know how to do that with snmptt, although somebody else might have done that.
                          Zabbix 3.0 Network Monitoring book

                          Comment

                          • MrKen
                            Senior Member
                            • Oct 2008
                            • 652

                            #14
                            To send the traps to the correct host you would need some sort of mapfile like pierky.wordpress.

                            What I did with snmptt was to send Cisco traps to a host called Cisco, Juniper traps to a host called Juniper, etc. You can configure that in snmptt when you do the snmpttconvertmib.

                            HTH
                            MrKen
                            Disclaimer: All of the above is pure speculation.

                            Comment

                            • Silvery
                              Junior Member
                              Zabbix Certified Specialist
                              • Oct 2008
                              • 28

                              #15
                              With snmptt you can bind traps to different hosts very easy.
                              Just replace the Hostname in the EXEC-Command with the variable $r like this:

                              EXEC /usr/local/sbin/zabbix_sender -z Zabbix-Server-IP -p 10051 -s $r -k snmptraps -o "...."

                              P.S. DNS must be enabled!

                              Some other snmptt variables:
                              http://www.snmptt.org/docs/snmptt.sh...-substitutions
                              Last edited by Silvery; 23-12-2009, 12:03.

                              Comment

                              Working...