[ovs-dev] [PATCH] ovs-bugtool: Add --help message.
Alex Wang
alexw at nicira.com
Sat Jan 24 03:06:12 UTC 2015
Thx for fixing this,
--output-fd=FD is not valid option, do you mean --outfile and --outfd ?
Otherwise, looks good~
Acked-by: Alex Wang <alexw at nicira.com>
On Fri, Jan 23, 2015 at 3:19 PM, Ben Pfaff <blp at nicira.com> wrote:
> Seemed a little embarrassing when I realized that ovs-bugtool has no usage
> message on a customer call this morning.
>
> Signed-off-by: Ben Pfaff <blp at nicira.com>
> ---
> utilities/bugtool/ovs-bugtool.in | 30 +++++++++++++++++++++++++++++-
> 1 file changed, 29 insertions(+), 1 deletion(-)
>
> diff --git a/utilities/bugtool/ovs-bugtool.in b/utilities/bugtool/
> ovs-bugtool.in
> index 75fcd0e..2ede359 100755
> --- a/utilities/bugtool/ovs-bugtool.in
> +++ b/utilities/bugtool/ovs-bugtool.in
> @@ -14,7 +14,7 @@
> # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
> USA
> #
> # Copyright (c) 2005, 2007 XenSource Ltd.
> -# Copyright (c) 2010, 2011, 2012, 2013 Nicira, Inc.
> +# Copyright (c) 2010, 2011, 2012, 2013, 2015 Nicira, Inc.
>
> #
> # To add new entries to the bugtool, you need to:
> @@ -383,6 +383,34 @@ def main(argv=None):
> only_ovs_info = False
> collect_all_info = True
>
> + if '--help' in sys.argv:
> + print """\
> +%(argv0)s: create status report bundles to assist in problem diagnosis
> +usage: %(argv0)s OPTIONS
> +
> +By default, %(argv0)s prompts for permission to collect each form of
> status
> +information and produces a .tar.gz file as output.
> +
> +The following options are available.
> + --help display this help message, then exit
> + -s, --silent suppress most output to stdout
> +
> +Options for categories of data to collect:
> + --entries=CAP_A,CAP_B,... set categories of data to collect
> + --all collect all categories
> + --ovs collect only directly OVS-related info
> + --log-days=DAYS collect DAYS worth of old logs
> + -y, --yestoall suppress prompts to confirm collection
> + --capabilities print categories as XML on stdout, then exit
> +
> +Output options:
> + --output=FORMAT set output format to one of tar tar.bz2
> tar.gz zip
> + --output-fd=FD send output to FD instead of to a file
> + --unlimited ignore default limits on sizes of data
> collected
> + --debug print ovs-bugtool debug info on stdout\
> +""" % {'argv0': sys.argv[0]}
> + sys.exit(0)
> +
> # we need access to privileged files, exit if we are not running as
> root
> if os.getuid() != 0:
> print >>sys.stderr, "Error: ovs-bugtool must be run as root"
> --
> 1.7.10.4
>
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev
>
More information about the dev
mailing list