From: Dave S. <D.T...@li...> - 2012-02-29 09:10:58
|
On 29 February 2012 08:30, Zeljko Mihelcic <zel...@er...> wrote: > c) "and so on..." means: elements/parameters in SNMP v2 protocol e.g.. As in an example > > time 14:02:55.912422 > source 10.93.112.14.32771 > destination 10.140.20.69.162 > .1.3.6.1.2.1.1.3(sysUpTime ) 1246333 > .1.3.6.1.6.3.1.1.4.1(snmpTrapOID) .1.3.6.1.4.1.193.109.2.0.3(elnLinkUp) > .1.3.6.1.4.1.193.72.500.1.1.0 (param1...managedObjectClass) EAN > .1.3.6.1.4.1.193.72.500.1.2.0 (param2...managedObjectInstance) EAN=10.93.112.14,EFN324xf,Port=1002.0.12 > .1.3.6.1.4.1.193.72.500.1.3.0 (param3...sequenceNumber) 24 > .1.3.6.1.4.1.193.72.500.1.4.0 (param4...perceivedSeverity) 1 > .1.3.6.1.4.1.193.72.500.1.5.0 (param5...eventTime) 07_dc_01_11_0d_02_37_59_2b_00_00 > .1.3.6.1.4.1.193.72.500.1.6.0 (param6...eventTypePem) 2 > .1.3.6.1.4.1.193.72.500.1.7.0 (param7...probableCause) 65 Try the command snmptrap -v 2c -c public 10.140.20.69 '' .1.3.6.1.4.1.193.109.2.0.3 .1.3.6.1.4.1.193.72.500.1.1.0 s "EAN" .1.3.6.1.4.1.193.72.500.1.2.0 s "EAN=10.93.112.14,EFN324xf,Port=1002.0.12" .1.3.6.1.4.1.193.72.500.1.3.0 i 24 .1.3.6.1.4.1.193.72.500.1.4.0 i 1 .1.3.6.1.4.1.193.72.500.1.4.0 x 0x07dc01110d0237592b0000 .1.3.6.1.4.1.193.72.500.1.6.0 i 2 .1.3.6.1.4.1.193.72.500.1.7.0 i 65 (all on one line). You may need to tweak the types/values a bit - you haven't said anything about the syntax/definitions of these MIB objects, so I've been forced to guess. But that should give you the basic idea. > e) Reading FAQ "How can I get the agent to send an SNMPv1 (or SNMPv2c) trap?" That question is talking about how to get the *agent* to send a trap. You've been asking about how to use "snmptrap" to send the trap. These are two very different approaches - don't try to equate the two. Dave |