SNMPv2 "ipv6IfStatsInHdrErrors" counter error
Subsystems (3)
cover SNMPv2 "ipv6IfStatsInHdrErrors" counter error
Hi, All
When I tested Linux kernel 2.6.17.7 about statistics
"ipv6IfStatsInHdrErrors", found that this counter couldn't increase correctly. The criteria is RFC2465:
ipv6IfStatsInHdrErrors OBJECT-TYPE
SYNTAX Counter3
MAX-ACCESS read-only
STATUS current
DESCRIPTION
"The number of input datagrams discarded due to errors in their IPv6 headers, including version number mismatch, other format errors, hop count exceeded, errors discovered in processing their IPv6 options, etc."
::= { ipv6IfStatsEntry 2 }
When I send TTL=0 and TTL=1 a packet to a router which need to be forwarded, router just sends an ICMPv6 message to tell the sender that TIME_EXCEED and HOPLIMITS, but no increments for this counter(in the function ip6_forward).
The following is the patch for this issue.
net/ipv6/ip6_output.c +1 -0
@@ -356,6 +356,7 @@ skb->dev = dst->dev;icmpv6_send (skb,ICMPV6_TIME_EXCEED ,ICMPV6_EXC_HOPLIMIT ,0 , skb->dev); +IP6_INC_STATS_BH (IPSTATS_MIB_INHDRERRORS );kfree_skb (skb);return -ETIMEDOUT ;
Regards
Wei Dong
Hello.
Next time, please put your "Signed-off-by" line before the patch. Thank you.
In article <1154425534.3329.2.camel@LINE> (at Tue, 01 Aug 2006 05:45:33 -0400), weidong <[email protected]> says:
Quoted 1 line
Signed-off-by Wei Dong <[email protected]>
--yoshfuji
David Miller
maintainerFrom: YOSHIFUJI Hideaki <[email protected]>
Date: Mon, 31 Jul 2006 18:36:25 +0900 (JST)
Quoted 9 lines
Hello.
Next time, please put your "Signed-off-by" line before the patch. Thank you.
In article <1154425534.3329.2.camel@LINE> (at Tue, 01 Aug 2006 05:45:33 -0400), weidong <[email protected]> says:
Quoted 1 line
Signed-off-by Wei Dong <[email protected]>
Patch applied, thanks.