[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <49EEA7E3.3080507@cosmosbay.com>
Date: Wed, 22 Apr 2009 07:15:15 +0200
From: Eric Dumazet <dada1@...mosbay.com>
To: Neil Horman <nhorman@...driver.com>
CC: netdev@...r.kernel.org, davem@...emloft.net
Subject: Re: [PATCH] snmp: add missing counters for RFC 4293
Neil Horman a écrit :
> Hey all-
> New patch, taking Erics commentary pointing out my prior stupidity into
> account :).
>
>
> The IP MIB (RFC 4293) defines stats for InOctets, OutOctets, InMcastOctets and
> OutMcastOctets:
> http://tools.ietf.org/html/rfc4293
> But it seems we don't track those in any way that easy to separate from other
> protocols. This patch adds those missing counters to the stats file. Tested
> successfully by me
Well, looking now at the patch again, I think you cannot add new fields
without breaking existing apps. My previous review stoped at this _BH thing
wihthout looking further :)
Also, it seems some RFC4293 items are already handled, since commit d831666e
from Mitsuru Chinen. Check net/ipv4/proc.c, line 114
/* Following RFC4293 items are displayed in /proc/net/netstat */
static const struct snmp_mib snmp4_ipextstats_list[] = {
SNMP_MIB_ITEM("InNoRoutes", IPSTATS_MIB_INNOROUTES),
SNMP_MIB_ITEM("InTruncatedPkts", IPSTATS_MIB_INTRUNCATEDPKTS),
SNMP_MIB_ITEM("InMcastPkts", IPSTATS_MIB_INMCASTPKTS),
SNMP_MIB_ITEM("OutMcastPkts", IPSTATS_MIB_OUTMCASTPKTS),
SNMP_MIB_ITEM("InBcastPkts", IPSTATS_MIB_INBCASTPKTS),
SNMP_MIB_ITEM("OutBcastPkts", IPSTATS_MIB_OUTBCASTPKTS),
SNMP_MIB_SENTINEL
};
# grep IpExt /proc/net/netstat
IpExt: InNoRoutes InTruncatedPkts InMcastPkts OutMcastPkts InBcastPkts OutBcastPkts
IpExt: 0 0 0 0 5089 0
So you might add items after existing ones, in IpExt preferably, in order not
breaking old applications.
Thanks
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists