[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20171110065727.GM18825@mtr-leonro.local>
Date: Fri, 10 Nov 2017 08:57:27 +0200
From: Leon Romanovsky <leon@...nel.org>
To: Ivan Vecera <ivecera@...hat.com>
Cc: netdev@...r.kernel.org, jiri@...lanox.com, arkadis@...lanox.com
Subject: Re: [PATCH iproute2 2/2] devlink: add batch command support
On Fri, Nov 10, 2017 at 07:20:14AM +0100, Ivan Vecera wrote:
> The patch adds support to batch devlink commands.
>
> Cc: Jiri Pirko <jiri@...lanox.com>
> Cc: Arkadi Sharshevsky <arkadis@...lanox.com>
> Signed-off-by: Ivan Vecera <ivecera@...hat.com>
> ---
> devlink/devlink.c | 70 +++++++++++++++++++++++++++++++++++++++++++++++-------
> man/man8/devlink.8 | 16 +++++++++++++
> 2 files changed, 78 insertions(+), 8 deletions(-)
>
<..>
> diff --git a/man/man8/devlink.8 b/man/man8/devlink.8
> index a480766c..a975ef34 100644
> --- a/man/man8/devlink.8
> +++ b/man/man8/devlink.8
> @@ -12,6 +12,12 @@ devlink \- Devlink tool
> .sp
>
> .ti -8
> +.B devlink
> +.RB "[ " -force " ] "
> +.BI "-batch " filename
> +.sp
> +
> +.ti -8
> .IR OBJECT " := { "
> .BR dev " | " port " | " monitor " }"
> .sp
> @@ -32,6 +38,16 @@ Print the version of the
> utility and exit.
>
> .TP
> +.BR "\-b", " \-batch " <FILENAME>
> +Read commands from provided file or standard input and invoke them.
> +First failure will cause termination of devlink.
It is worth to document the expected format of that file.
And IMHO, it is better to have ability to load JSON fie which was
generated by -j, instead of declaring new format/knob.
> +
> +.TP
> +.BR "\-force"
> +Don't terminate devlink on errors in batch mode.
> +If there were any errors during execution of the commands, the application return code will be non zero.
> +
> +.TP
> .BR "\-n" , " --no-nice-names"
> Turn off printing out nice names, for example netdevice ifnames instead of devlink port identification.
>
> --
> 2.13.6
>
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists