mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
Dashes for zero latency values in zpool iostat -p
This prints dashes instead of zeros for zero latency values in 'zpool iostat -p'. You'll get zero latencies reported when the disk is idle, but technically a zero latency is invalid, since you can't measure the latency of doing nothing. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: George Melikov <mail@gmelikov.ru> Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #6210
This commit is contained in:
committed by
Brian Behlendorf
parent
d9ad3fea3b
commit
29eb494285
+11
-1
@@ -775,11 +775,21 @@ extern int zfs_unshareall(zfs_handle_t *);
|
||||
extern int zfs_deleg_share_nfs(libzfs_handle_t *, char *, char *, char *,
|
||||
void *, void *, int, zfs_share_op_t);
|
||||
|
||||
/*
|
||||
* Formats for iostat numbers. Examples: "12K", "30ms", "4B", "2321234", "-".
|
||||
*
|
||||
* ZFS_NICENUM_1024: Print kilo, mega, tera, peta, exa..
|
||||
* ZFS_NICENUM_BYTES: Print single bytes ("13B"), kilo, mega, tera...
|
||||
* ZFS_NICENUM_TIME: Print nanosecs, microsecs, millisecs, seconds...
|
||||
* ZFS_NICENUM_RAW: Print the raw number without any formatting
|
||||
* ZFS_NICENUM_RAWTIME: Same as RAW, but print dashes ('-') for zero.
|
||||
*/
|
||||
enum zfs_nicenum_format {
|
||||
ZFS_NICENUM_1024 = 0,
|
||||
ZFS_NICENUM_BYTES = 1,
|
||||
ZFS_NICENUM_TIME = 2,
|
||||
ZFS_NICENUM_RAW = 3
|
||||
ZFS_NICENUM_RAW = 3,
|
||||
ZFS_NICENUM_RAWTIME = 4
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user