Re: snmptrapd - parse fail not logging trap
Andy Brown <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <[email protected]> |
On 01/03/11 12:17, Dave Shield wrote: > On 1 March 2011 11:03, Andy Brown<[email protected]> wrote: >> Having a right time with snmptrapd here, got it working perfectly on one >> ubuntu server, and on another, supposedly identical, no go, it fails to >> receive/log the traps sent to it (from the same hardware). >> >> Can anyone assist in debugging the logs here and help me get it logging >> (all I need is it to log any traps sent to the syslog) > > >> The debug trace seems to point to the error, but I cannot figure out >> why/what it means > > The parsing seems to handle the trap header OK - but it's failing > as soon as it starts to parse the varbind list. Unfortunately there's > no detail of what it's received here, and hence why it's getting confused. > > Can you try running the trap receiver using the '-d' flag, which will > dump the raw incoming packet before it starts to process it. > That (plus "-Drecv") might give us a bit more to work with. > > Dave Hi Dave, thanks for the fast reply. I'd not be surprised if the device sending the traps sends them malformed or buggy, so we could be onto something. I've logged with both debugs and the traps are definitely in there: Mar 1 12:39:11 lanserv1 snmptrapd[1149]: #012Sending 20 bytes to Local IPC: /var/agentx/master Mar 1 12:39:11 lanserv1 snmptrapd[1149]: 0000: 01 0D 00 00 05 00 00 00 00 00 00 00 07 3F 59 31 .............?Y1 Mar 1 12:39:11 lanserv1 snmptrapd[1149]: 0016: 00 00 00 00 .... Mar 1 12:39:11 lanserv1 snmptrapd[1149]: Mar 1 12:39:11 lanserv1 snmptrapd[1149]: #012Received 28 bytes from Local IPC: abstract Mar 1 12:39:11 lanserv1 snmptrapd[1149]: 0000: 01 12 00 00 05 00 00 00 00 00 00 00 07 3F 59 31 .............?Y1 Mar 1 12:39:11 lanserv1 snmptrapd[1149]: 0016: 08 00 00 00 78 52 00 00 00 00 00 00 ....xR...... Mar 1 12:39:11 lanserv1 snmptrapd[1149]: Mar 1 12:39:16 lanserv1 snmptrapd[1149]: #012Received 97 bytes from UDP: [192.168.2.14]:7878->[192.168.2.5] Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0000: 30 81 5E 02 01 00 04 06 70 75 62 6C 69 63 A4 4B 0.^.....public.K Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0016: 06 07 2B 06 01 04 01 5C 0C 40 04 C0 A8 02 0E 02 ..+....\.@...... Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0032: 01 06 02 01 00 43 04 00 56 55 16 30 34 30 32 06 .....C..VU.0402. Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0048: 07 2B 06 01 04 01 5C 0C 04 27 32 30 31 31 30 33 .+....\..'201103 Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0064: 30 31 5F 31 32 33 39 30 33 5E 39 32 31 32 20 2D 01_123903^9212 - Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0080: 2D 3E 20 4F 55 54 35 20 3D 20 4F 46 46 20 20 21 -> OUT5 = OFF ! Mar 1 12:39:16 lanserv1 snmptrapd[1149]: 0096: 21 ! Mar 1 12:39:16 lanserv1 snmptrapd[1149]: Mar 1 12:39:18 lanserv1 snmptrapd[1149]: #012Received 96 bytes from UDP: [192.168.2.14]:7878->[192.168.2.5] Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0000: 30 81 5D 02 01 00 04 06 70 75 62 6C 69 63 A4 4B 0.].....public.K Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0016: 06 07 2B 06 01 04 01 5C 0C 40 04 C0 A8 02 0E 02 ..+....\.@...... Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0032: 01 06 02 01 00 43 04 00 56 56 0E 30 33 30 31 06 .....C..VV.0301. Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0048: 07 2B 06 01 04 01 5C 0C 04 26 32 30 31 31 30 33 .+....\..&201103 Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0064: 30 31 5F 31 32 33 39 30 35 5E 39 32 31 32 20 2D 01_123905^9212 - Mar 1 12:39:18 lanserv1 snmptrapd[1149]: 0080: 2D 3E 20 4F 55 54 35 20 3D 20 4F 4E 20 20 21 21 -> OUT5 = ON !! Mar 1 12:39:18 lanserv1 snmptrapd[1149]: Mar 1 12:39:26 lanserv1 snmptrapd[1149]: #012Sending 20 bytes to Local IPC: /var/agentx/master Mar 1 12:39:26 lanserv1 snmptrapd[1149]: 0000: 01 0D 00 00 05 00 00 00 00 00 00 00 08 3F 59 31 .............?Y1 Mar 1 12:39:26 lanserv1 snmptrapd[1149]: 0016: 00 00 00 00 .... Mar 1 12:39:26 lanserv1 snmptrapd[1149]: Mar 1 12:39:26 lanserv1 snmptrapd[1149]: #012Received 28 bytes from Local IPC: abstract Mar 1 12:39:26 lanserv1 snmptrapd[1149]: 0000: 01 12 00 00 05 00 00 00 00 00 00 00 08 3F 59 31 .............?Y1 Mar 1 12:39:26 lanserv1 snmptrapd[1149]: 0016: 08 00 00 00 55 58 00 00 00 00 00 00 ....UX...... Mar 1 12:39:26 lanserv1 snmptrapd[1149]: -- Andy e: andy @ thebmwz3.co.uk e: andy @ broadcast-tech.co.uk w: http://www.thebmwz3.co.uk w: http://www.broadcast-tech.co.uk ------------------------------------------------------------------------------ Free Software Download: Index, Search & Analyze Logs and other IT data in Real-Time with Splunk. Collect, index and harness all the fast moving IT data generated by your applications, servers and devices whether physical, virtual or in the cloud. Deliver compliance at lower cost and gain new business insights. http://p.sf.net/sfu/splunk-dev2dev _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users