Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Dec 2010 10:30:15 GMT
From:      Bruce Evans <brde@optusnet.com.au>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/153012: iostat(8) requires an argument to -c option
Message-ID:  <201012111030.oBBAUFLh059156@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/153012; it has been noted by GNATS.

From: Bruce Evans <brde@optusnet.com.au>
To: Warren Block <wblock@wonkity.com>
Cc: freebsd-gnats-submit@FreeBSD.org, freebsd-bugs@FreeBSD.org
Subject: Re: bin/153012: iostat(8) requires an argument to -c option
Date: Sat, 11 Dec 2010 21:23:19 +1100 (EST)

 On Fri, 10 Dec 2010, Warren Block wrote:
 
 >> Description:
 > iostat(8) says:
 >
 > -c    Repeat the display count times.  If no repeat count is specified,
 >      the default is infinity.
 
 This used to be correct.  It said "if no wait interval is specified, then
 the default [for the wait interval] is 1 second".  This was a bit confusing
 since it didn't say that the default is for the wait interval.  Now it is
 just broken, since it is the -c option and not its repeat count that is
 optional.
 
 > But if you try to run it without a repeat count:
 >
 > % iostat -c
 > iostat: option requires an argument -- c
 > usage: iostat [-CdhIKoTxz?] [-c count] [-M core] [-n devs] [-N system]
 > 	      [-t type,if,pass] [-w wait] [drives]
 
 The synopsis and usage message correctly specify that -c must have an arg.
 
 The -w option has the complement of this breakage.
 
 Either -w wait or the the normal way using the undocumented alias for this
 ("iostat wait", where `wait is a number') must be used to specifiy the wait
 time for -c.  Not documenting this may be intentional, but it became
 especially broken when the `drives' option was added, since according to
 the synopsis and usage message "iostat 1" says to give statistics for the
 drive named "1", but it is actually an alias for "iostat -w 1".
 
 Bruce



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201012111030.oBBAUFLh059156>