]> git.proxmox.com Git - mirror_zfs.git/commitdiff
list -o props should be alloc,free not used,avail
authorTom Matthews <tomtastic@users.noreply.github.com>
Tue, 4 Apr 2017 18:03:33 +0000 (19:03 +0100)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 4 Apr 2017 18:03:33 +0000 (11:03 -0700)
Manpage suggests the zpool list properties include 'used'
and 'available', when these are invalid property names.
Use alloc and free in their place.

```
$ zpool list -o name,size,used   2>&1 |head -1
bad property list: invalid property 'used'
$ zpool list -o name,size,avail   2>&1 |head -1
bad property list: invalid property 'avail'
$ zpool list -o name,size,available   2>&1 |head -1
bad property list: invalid property 'available'
$ zpool list -o name,size,alloc,free
NAME    SIZE  ALLOC   FREE
apool   464M   203M   261M
bpool  3.62T  1.97T  1.65T
```

Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Reviewed-by: loli10K <ezomori.nozomu@gmail.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tom Matthews <tom@axiom-partners.com>
Closes #5959

man/man8/zpool.8
tests/zfs-tests/tests/functional/cli_user/zpool_list/zpool_list_001_pos.ksh

index 929340fcbcff4d7fabcaccdbcda10bf683de7f46..0c053b08058e44595bb1c7ee906863b17a83d6cd 100644 (file)
@@ -1877,7 +1877,7 @@ Specify \fBu\fR for a printed representation of the internal representation of t
 \fB\fB-o\fR \fIprops\fR\fR
 .ad
 .RS 12n
-Comma-separated list of properties to display. See the "Properties" section for a list of valid properties. The default list is "name, size, used, available, fragmentation, expandsize, capacity, dedupratio, health, altroot"
+Comma-separated list of properties to display. See the "Properties" section for a list of valid properties. The default list is "name, size, alloc, free, fragmentation, expandsize, capacity, dedupratio, health, altroot"
 .RE
 
 .sp
index 4de88675fc37e80991332cd98156db4ca95ced4b..29283cc072a03d3ff8996e2f3eb1396f8411e752 100755 (executable)
@@ -50,8 +50,8 @@ fi
 set -A args "list $TESTPOOL" "list -H $TESTPOOL" "list" "list -H" \
     "list -H -o name $TESTPOOL" "list -o name $TESTPOOL" \
     "list -o name,size,capacity,health,altroot $TESTPOOL" \
-    "list -H -o name,size,capacity,health,altroot $TESTPOOL"
-
+    "list -H -o name,size,capacity,health,altroot $TESTPOOL" \
+    "list -o alloc,free $TESTPOOL"
 log_assert "zpool list [-H] [-o filed[,filed]*] [<pool_name> ...]"
 
 typeset -i i=0