lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <DB5PR05MB1895E5D25BFD05D416EB11FDAC730@DB5PR05MB1895.eurprd05.prod.outlook.com>
Date:   Sun, 22 Jan 2017 15:34:45 +0000
From:   Nogah Frankel <nogahf@...lanox.com>
To:     Stephen Hemminger <stephen@...workplumber.org>,
        Roopa Prabhu <roopa@...ulusnetworks.com>
CC:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "roszenrami@...il.com" <roszenrami@...il.com>,
        Jiri Pirko <jiri@...lanox.com>,
        Ido Schimmel <idosch@...lanox.com>,
        Elad Raz <eladr@...lanox.com>,
        Yotam Gigi <yotamg@...lanox.com>,
        Or Gerlitz <ogerlitz@...lanox.com>
Subject: RE: [PATCH iproute2 v4 3/4] ifstat: Add 64 bits based stats to
 extended statistics


> -----Original Message-----
> From: Stephen Hemminger [mailto:stephen@...workplumber.org]
> Sent: Thursday, January 19, 2017 9:11 PM
> To: Roopa Prabhu <roopa@...ulusnetworks.com>
> Cc: Nogah Frankel <nogahf@...lanox.com>; netdev@...r.kernel.org;
> roszenrami@...il.com; Jiri Pirko <jiri@...lanox.com>; Ido Schimmel
> <idosch@...lanox.com>; Elad Raz <eladr@...lanox.com>; Yotam Gigi
> <yotamg@...lanox.com>; Or Gerlitz <ogerlitz@...lanox.com>
> Subject: Re: [PATCH iproute2 v4 3/4] ifstat: Add 64 bits based stats to extended statistics
> 
> On Thu, 19 Jan 2017 08:06:21 -0800
> Roopa Prabhu <roopa@...ulusnetworks.com> wrote:
> 
> > On 1/19/17, 7:21 AM, Nogah Frankel wrote:
> > >> -----Original Message-----
> > >> From: Nogah Frankel
> > >> Sent: Sunday, January 15, 2017 3:55 PM
> > >> To: 'Stephen Hemminger' <stephen@...workplumber.org>
> > >> Cc: netdev@...r.kernel.org; roszenrami@...il.com;
> roopa@...ulusnetworks.com; Jiri
> > >> Pirko <jiri@...lanox.com>; Ido Schimmel <idosch@...lanox.com>; Elad Raz
> > >> <eladr@...lanox.com>; Yotam Gigi <yotamg@...lanox.com>; Or Gerlitz
> > >> <ogerlitz@...lanox.com>
> > >> Subject: RE: [PATCH iproute2 v4 3/4] ifstat: Add 64 bits based stats to extended
> statistics
> > >>
> > >>
> > >>
> > >>> -----Original Message-----
> > >>> From: Stephen Hemminger [mailto:stephen@...workplumber.org]
> > >>> Sent: Friday, January 13, 2017 3:44 AM
> > >>> To: Nogah Frankel <nogahf@...lanox.com>
> > >>> Cc: netdev@...r.kernel.org; roszenrami@...il.com;
> roopa@...ulusnetworks.com;
> > >> Jiri
> > >>> Pirko <jiri@...lanox.com>; Ido Schimmel <idosch@...lanox.com>; Elad Raz
> > >>> <eladr@...lanox.com>; Yotam Gigi <yotamg@...lanox.com>; Or Gerlitz
> > >>> <ogerlitz@...lanox.com>
> > >>> Subject: Re: [PATCH iproute2 v4 3/4] ifstat: Add 64 bits based stats to extended
> statistics
> > >>>
> > >>> On Thu, 12 Jan 2017 15:49:50 +0200
> > >>> Nogah Frankel <nogahf@...lanox.com> wrote:
> > >>>
> > >>>> The default stats for ifstat are 32 bits based.
> > >>>> The kernel supports 64 bits based stats. (They are returned in struct
> > >>>> rtnl_link_stats64 which is an exact copy of struct rtnl_link_stats, in
> > >>>> which the "normal" stats are returned, but with fields of u64 instead of
> > >>>> u32). This patch adds them as an extended stats.
> > >>>>
> > >>>> It is read with filter type IFLA_STATS_LINK_64 and no sub type.
> > >>>>
> > >>>> It is under the name 64bits
> > >>>> (or any shorten of it as "64")
> > >>>>
> > >>>> For example:
> > >>>> ifstat -x 64bit
> > >>>>
> > >>>> Signed-off-by: Nogah Frankel <nogahf@...lanox.com>
> > >>>> Reviewed-by: Jiri Pirko <jiri@...lanox.com>
> > >>> Other commands (like ip link) always use the 64 bit statistics if available
> > >>> from the device. I see no reason that ifstat needs to be different.
> > >>>
> > >> Do you mean to change the default ifstat results to be 64 bits based?
> > >> I tried it in the first version, but Roopa commented that it was not a good idea.
> > >> She said they tried it in the past and it caused backward compatibilities problems.
> > >> (Or maybe I didn't understand correctly)
> > > So, can I leave the default ifstat results to be 32 bits based, for the time being?
> > >
> > From past discussions: Moving the default to 64bit has compat issues with the old
> history file.
> > There is a way to make it work by using a new file header (to indicate that it is 64 bit) in
> > a freshly created history file and also check this header before dumping stats into the
> history file.
> > ie maintain backward compat without introducing a new option. It is doable.
> >
> > One approach is, you can drop the 64bit option from this series and
> > try updating the default to 64 bit (with compat handling code) in a later series.

I think I will take your suggestion to drop the 64 bits from this series.
Hopefully, I'll return to it in some later series in the future.
Thanks

> 
> The ifstat code could do conversion based on file size.
> 
>   if (history_file_is_32bit()) {
> 	printf("converting to 64 bit format\n");
>         ...
>   }
> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ