about linkupdown traps

bhushan <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
hello friends,
Greetings
i am using netsnmp-5.4 , following is my snmpd.conf file

 com2sec my_user 0.0.0.0/0 public
 group MyGroup usm my_user
 view basic included .1.3.6.1.2.1.1
 view basic included .1.3.6.1.2.1.2
 view basic included .1.3.6.1.2.1.3
 view basic included .1.3.6.1.2.1.4
 view basic included .1.3.6.1.2.1.5
 view basic included .1.3.6.1.2.1.6
 view basic included .1.3.6.1.2.1.7
 view basic included .1.3.6.1.2.1.8
 agentSecName my_user
 linkUpDownNotifications yes
 authtrapenable  1
 trap2sink 127.0.0.1 public
 view basic included .1.3.6.1.2.1.10
 access MyGroup  "" any authPriv exact basic none none

 I have created snmpv3 user named my_user using net-snmp-config
--create-snmpv3-user
 command, i.e. i am able to do snmpwalk using my_user.
 but i am facing one problem in agentSecName directive
 i am making my interface up/down so as snmpd generate link up/down trap
 my problem is link up/down trap not generated by snmpd
 instead of that auth failure trap are
 generated by snmpd. i think when agent query to itself for ifOperStatus to
find wheather link up/down at that
 time it fails to get that data i.e. ifOperStatus.
 following is dump of my agent when i run it as snmpd -Lo -f -d


[root@wifi-security-server .libs]# ./snmpd -Lo -f -d -c /etc/snmp/snmpd.conf
Turning on AgentX master support.


Sending 95 bytes to UDP: [127.0.0.1]:162
0000: 30 5D 02 01  01 04 06 70  75 62 6C 69  63 A7 50 02    0].....public.P.
0016: 04 68 63 AE  21 02 01 00  02 01 00 30  42 30 0D 06    .hc.!......0B0..
0032: 08 2B 06 01  02 01 01 03  00 43 01 27  30 17 06 0A    .+.......C.'0...
0048: 2B 06 01 06  03 01 01 04  01 00 06 09  2B 06 01 06    +...........+...
0064: 03 01 01 05  01 30 18 06  0A 2B 06 01  06 03 01 01    .....0...+......
0080: 04 03 00 06  0A 2B 06 01  04 01 BF 08  03 02 0A       .....+.........


NET-SNMP version 5.4


Sending 1 bytes to callback: 2 on fd 5
0000: 00                                                    .




Received 1 bytes from callback: 1 on fd 3
0000: 00                                                    .


Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus


Sending 95 bytes to UDP: [127.0.0.1]:162
0000: 30 5D 02 01  01 04 06 70  75 62 6C 69  63 A7 50 02    0].....public.P.
0016: 04 68 63 AE  23 02 01 00  02 01 00 30  42 30 0D 06    .hc.#......0B0..
0032: 08 2B 06 01  02 01 01 03  00 43 01 28  30 17 06 0A    .+.......C.(0...
0048: 2B 06 01 06  03 01 01 04  01 00 06 09  2B 06 01 06    +...........+...
0064: 03 01 01 05  05 30 18 06  0A 2B 06 01  06 03 01 01    .....0...+......
0080: 04 03 00 06  0A 2B 06 01  04 01 BF 08  03 02 0A       .....+.........




Sending 1 bytes to callback: 1 on fd 3
0000: 3C                                                    <
Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .
failed to run mteTrigger query
Sending 1 bytes to callback: 2 on fd 5
0000: FC
Received 1 bytes from callback: 1 on fd 3
0000: FC                                                    .
Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus

Sending 95 bytes to UDP: [127.0.0.1]:162
0000: 30 5D 02 01  01 04 06 70  75 62 6C 69  63 A7 50 02    0].....public.P.
0016: 04 68 63 AE  25 02 01 00  02 01 00 30  42 30 0D 06    .hc.%......0B0..
0032: 08 2B 06 01  02 01 01 03  00 43 01 2A  30 17 06 0A    .+.......C.*0...
0048: 2B 06 01 06  03 01 01 04  01 00 06 09  2B 06 01 06    +...........+...
0064: 03 01 01 05  05 30 18 06  0A 2B 06 01  06 03 01 01    .....0...+......
0080: 04 03 00 06  0A 2B 06 01  04 01 BF 08  03 02 0A       .....+.........

Sending 1 bytes to callback: 1 on fd 3
0000: 2C                                                    ,
Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .
failed to run mteTrigger query


i have also started snmptrapd  as snmptrapd -Lo -f
so on it console i am receiving following messages

[root@wifi-security-server root]# snmptrapd -Lo -f
2006-12-18 17:38:25 NET-SNMP version 5.2.3 Started.
2006-12-18 17:38:26 localhost.localdomain [UDP: [127.0.0.1]:32787]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (43) 0:00:00.43    SNMPv2-MIB::
snmpTrapOID.0 = OID: SNMPv2-MIB::coldStart
SNMPv2-MIB::snmpTrapEnterprise.0= OID: NET-SNMP-MIB::
netSnmpAgentOIDs.10
2006-12-18 17:38:26 localhost.localdomain [UDP: [127.0.0.1]:32787]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (45) 0:00:00.45    SNMPv2-MIB::
snmpTrapOID.0 = OID: SNMPv2-MIB::authenticationFailure  SNMPv2-MIB::
snmpTrapEnterprise.0 = OID: NET-SNMP-MIB::netSnmpAgentOIDs.10
2006-12-18 17:38:26 localhost.localdomain [UDP: [127.0.0.1]:32787]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (48) 0:00:00.48    SNMPv2-MIB::
snmpTrapOID.0 = OID: SNMPv2-MIB::authenticationFailure  SNMPv2-MIB::
snmpTrapEnterprise.0 = OID: NET-SNMP-MIB::netSnmpAgentOIDs.10
2006-12-18 17:38:27 localhost.localdomain [UDP: [127.0.0.1]:32787]:


this means means that the user that i have specified in agentSecName
directive is
wrong, or what may be the problem ?
also one thing i want to tell you friends,
when i am not creating snmpv3 user using net-snmp-config
--create-snmpv3-user command
& specify snmpd.conf as follows, then my linkup & linkdown trap generated by
snmpd

agentSecName my_user
rouser my_user
linkUpDownNotifications yes
authtrapenable  1
trap2sink 127.0.0.1 public

for your understanding this are the log of

snmpd:

[root@wifi-security-server .libs]# ./snmpd -Lo -f -d -C -c
/etc/snmp/snmpd.conf.try
Sending 95 bytes to UDP: [127.0.0.1]:162
0000: 30 5D 02 01  01 04 06 70  75 62 6C 69  63 A7 50 02    0].....public.P.
0016: 04 63 77 7A  64 02 01 00  02 01 00 30  42 30 0D 06    .cwzd......0B0..
0032: 08 2B 06 01  02 01 01 03  00 43 01 1B  30 17 06 0A    .+.......C..0...
0048: 2B 06 01 06  03 01 01 04  01 00 06 09  2B 06 01 06    +...........+...
0064: 03 01 01 05  01 30 18 06  0A 2B 06 01  06 03 01 01    .....0...+......
0080: 04 03 00 06  0A 2B 06 01  04 01 BF 08  03 02 0A       .....+.........
NET-SNMP version 5.4
Sending 1 bytes to callback: 2 on fd 5
0000: 00                                                    .
Received 1 bytes from callback: 1 on fd 3
0000: 00                                                    .
Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus
Sending 1 bytes to callback: 1 on fd 3
0000: 00                                                    .
Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .
Sending 1 bytes to callback: 2 on fd 5
0000: A8                                                    .
Received 1 bytes from callback: 1 on fd 3
0000: A8
Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus.1
Sending 1 bytes to callback: 1 on fd 3
0000: 00                                                    .
Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .
Sending 1 bytes to callback: 2 on fd 5
0000: A8                                                    .
Received 1 bytes from callback: 1 on fd 3
0000: 00                                                    .
Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus.2
Sending 1 bytes to callback: 1 on fd 3
0000: 00                                                    .
Received 1 bytes from callback: 2 on fd 5
0000: FC
Sending 1 bytes to callback: 2 on fd 5
0000: 00
Received 1 bytes from callback: 1 on fd 3
0000: 00                                                    .
Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus.3
Sending 1 bytes to callback: 1 on fd 3
0000: 00                                                    .


Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .


Sending 1 bytes to callback: 2 on fd 5
0000: 00                                                    .


Received 1 bytes from callback: 1 on fd 3
0000: 00                                                    .

Received SNMP packet(s) from callback: 1 on fd 3
  GETNEXT message
    -- IF-MIB::ifOperStatus.4
Sending 1 bytes to callback: 1 on fd 3
0000: F8                                                    .
Received 1 bytes from callback: 2 on fd 5
0000: FC                                                    .
Sending 1 bytes to callback: 2 on fd 5
0000: A8                                                    .
Received 1 bytes from callback: 1 on fd 3
0000: A8
Received SNMP packet(s) from callback: 1 on fd 3
  GET message
Sending 1 bytes to callback: 1 on fd 3
0000: A8                                                    .
Received 1 bytes from callback: 2 on fd 5
0000: A8                                                    .
Sending 96 bytes to UDP: [127.0.0.1]:162
0000: 30 5E 02 01  01 04 06 70  75 62 6C 69  63 A7 51 02    0^.....public.Q.
0016: 04 63 77 7A  80 02 01 00  02 01 00 30  43 30 0E 06    .cwz.......0C0..
0032: 08 2B 06 01  02 01 01 03  00 43 02 17  8C 30 17 06    .+.......C...0..
0048: 0A 2B 06 01  06 03 01 01  04 01 00 06  09 2B 06 01    .+...........+..
0064: 06 03 01 01  05 03 30 18  06 0A 2B 06  01 06 03 01    ......0...+.....
0080: 01 04 03 00  06 0A 2B 06  01 04 01 BF  08 03 02 0A    ......+.........





snmptrapd:


[root@wifi-security-server root]# snmptrapd -Lo -f -d
2006-12-18 17:46:25 NET-SNMP version 5.2.3 Started.


Received 96 bytes from UDP: [127.0.0.1]:32788
0000: 30 5E 02 01  01 04 06 70  75 62 6C 69  63 A7 51 02    0^.....public.Q.
0016: 04 00 F9 BE  50 02 01 00  02 01 00 30  43 30 0E 06    ....P......0C0..
0032: 08 2B 06 01  02 01 01 03  00 43 02 17  97 30 17 06    .+.......C...0..
0048: 0A 2B 06 01  06 03 01 01  04 01 00 06  09 2B 06 01    .+...........+..
0064: 06 03 01 01  05 04 30 18  06 0A 2B 06  01 06 03 01    ......0...+.....
0080: 01 04 03 00  06 0A 2B 06  01 04 01 BF  08 03 02 0A    ......+.........


2006-12-18 17:47:17 localhost.localdomain [UDP: [127.0.0.1]:32788]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (6039) 0:01:00.39  SNMPv2-MIB::
snmpTrapOID.0 = OID: IF-MIB::linkUp SNMPv2-MIB::snmpTrapEnterprise.0 = OID:
NET-SNMP-MIB::netSnmpAgentOIDs.10


Received 96 bytes from UDP: [127.0.0.1]:32788
0000: 30 5E 02 01  01 04 06 70  75 62 6C 69  63 A7 51 02    0^.....public.Q.
0016: 04 00 F9 BE  52 02 01 00  02 01 00 30  43 30 0E 06    ....R......0C0..
0032: 08 2B 06 01  02 01 01 03  00 43 02 17  98 30 17 06    .+.......C...0..
0048: 0A 2B 06 01  06 03 01 01  04 01 00 06  09 2B 06 01    .+...........+..
0064: 06 03 01 01  05 04 30 18  06 0A 2B 06  01 06 03 01    ......0...+.....
0080: 01 04 03 00  06 0A 2B 06  01 04 01 BF  08 03 02 0A    ......+.........


2006-12-18 17:47:17 localhost.localdomain [UDP: [127.0.0.1]:32788]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (6040) 0:01:00.40  SNMPv2-MIB::
snmpTrapOID.0 = OID: IF-MIB::linkUp SNMPv2-MIB::snmpTrapEnterprise.0 = OID:
NET-SNMP-MIB::netSnmpAgentOIDs.10


Received 96 bytes from UDP: [127.0.0.1]:32788
0000: 30 5E 02 01  01 04 06 70  75 62 6C 69  63 A7 51 02    0^.....public.Q.
0016: 04 00 F9 BE  54 02 01 00  02 01 00 30  43 30 0E 06    ....T......0C0..
0032: 08 2B 06 01  02 01 01 03  00 43 02 17  98 30 17 06    .+.......C...0..
0048: 0A 2B 06 01  06 03 01 01  04 01 00 06  09 2B 06 01    .+...........+..
0064: 06 03 01 01  05 04 30 18  06 0A 2B 06  01 06 03 01    ......0...+.....
0080: 01 04 03 00  06 0A 2B 06  01 04 01 BF  08 03 02 0A    ......+.........

2006-12-18 17:47:17 localhost.localdomain [UDP: [127.0.0.1]:32788]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (6040) 0:01:00.40  SNMPv2-MIB::
snmpTrapOID.0 = OID: IF-MIB::linkUp SNMPv2-MIB::snmpTrapEnterprise.0 = OID:
NET-SNMP-MIB::netSnmpAgentOIDs.10

Received 96 bytes from UDP: [127.0.0.1]:32788
0000: 30 5E 02 01  01 04 06 70  75 62 6C 69  63 A7 51 02    0^.....public.Q.
0016: 04 00 F9 BE  5B 02 01 00  02 01 00 30  43 30 0E 06    ....[......0C0..
0032: 08 2B 06 01  02 01 01 03  00 43 02 17  98 30 17 06    .+.......C...0..
0048: 0A 2B 06 01  06 03 01 01  04 01 00 06  09 2B 06 01    .+...........+..
0064: 06 03 01 01  05 03 30 18  06 0A 2B 06  01 06 03 01    ......0...+.....
0080: 01 04 03 00  06 0A 2B 06  01 04 01 BF  08 03 02 0A    ......+.........

2006-12-18 17:47:17 localhost.localdomain [UDP: [127.0.0.1]:32788]:
SNMPv2-MIB::sysUpTime.0 = Timeticks: (6040) 0:01:00.40  SNMPv2-MIB::
snmpTrapOID.0 = OID: IF-MIB::linkDown
SNMPv2-MIB::snmpTrapEnterprise.0= OID: NET-SNMP-MIB::
netSnmpAgentOIDs.10



so what may be the  problem friends?
Thanks in advance
Regards
Bhushan

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

_______________________________________________
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
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.