On Aug 26, 2009, at 12:57 PM, Trond Myklebust wrote:
On Wed, 2009-08-26 at 11:47 -0400, Chuck Lever wrote:
On Aug 26, 2009, at 10:53 AM, Lans Carstensen wrote:
Greetings! Comments inline. Chuck Lever wrote:
Hi Lans-
I was thinking about this feature a little more. Would it be
interesting to allow sorting by other metrics besides ops/s ?
That's another feature that the "top" command has that this new
option doesn't.
I also don't like the bare integer options. What if, at some
point, we want "-4" and "-6" for IPv6 support (not that we do, but
what if)? Plus, having the bare integers doesn't give any clues
about what the number means.
In which case I propose:
--sort=ops --list=<n>
which provides more flexibility and helps make the options more
self-documenting.
Again, thanks for looking this over.
I had thought about the sorting a little bit, but decided that every
case we cared about devolved to sorting by ops/s. We'd use a tool
like this in an operational group where they've lost control of a
particular rogue workload in the mix of thousands of other
workloads, and the operational group is trying to figure out what
workload is generating a disproportionate amount of traffic (ops/
s). If someone wanted to extend the implementation further where
leaving "--sort" unadorned sorts by ops and using "--
sort=readdirplus" or somesuch, I'd be all for it - but it didn't
seem worth the work for our use. So I'd encourage that to be
adopted as-is and if someone wants to put the extra effort into it
I'm all for it.
Well, the problem is once we choose a command line option, it's hard
to change it later. I think having two choices, like --sort=ops
and --
sort=def[ault] would be fine for now, and give us room to grow later.
There is precedent for having both an option "--sort" with no
arguments,
and "--sort=". See for instance 'ls --color'/'ls --color=WHEN'.
We could therefore just add '--sort' for now, and then add a --
sort=KEY
type option when someone decides they need it.
If we are confident that having a "--sort" today will not limit
options later, then let's go for it.
--
Chuck Lever
chuck[dot]lever[at]oracle[dot]com
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html