[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 8 Aug 2018 09:26:46 -0700
From: Stephen Hemminger <stephen@...workplumber.org>
To: Dave Taht <dave.taht@...il.com>
Cc: mcroce@...hat.com,
Linux Kernel Network Developers <netdev@...r.kernel.org>
Subject: Re: [PATCH iproute2] ip link: don't stop batch processing
On Fri, 3 Aug 2018 11:08:58 -0700
Dave Taht <dave.taht@...il.com> wrote:
> On Fri, Aug 3, 2018 at 10:50 AM Matteo Croce <mcroce@...hat.com> wrote:
> >
> > When 'ip link show dev DEVICE' is processed in a batch mode, ip exits
> > and stop processing further commands.
> > This because ipaddr_list_flush_or_save() calls exit() to avoid printing
> > the link information twice.
> > Replace the exit with a classic goto out instruction.
> >
> > Signed-off-by: Matteo Croce <mcroce@...hat.com>
>
> one thing I noticed in iproute2-next last week is that
>
> ( echo qdisc show dev eno1; sleep 5; echo qdisc show dev eno1; ) | tc -b -
>
> batches the whole thing up to emerge on exit, only.
>
> It didn't used to do that, the output of every command came out as it
> completed. I used to use that to timestamp and save the overhead of
> invoking the tc utility on openwrt while monitoring qdisc stats in
> https://github.com/tohojo/flent/blob/master/misc/tc_iterate.c
There used to be lots of fflush(stdout) in each sub command but lots of these
got dropped in JSON updates.
I just added one back in after each batch command that should fix what you are seeing.
Powered by blists - more mailing lists