mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-25 02:49:32 +03:00
Fix option string, adding -e and fixing order
The recently added '-e' option (PR #15769) missed adding the new option in the online `zpool status` help command. This adds the options and reorders a couple of the other options that were not listed alphabetically. Reviewed-by: Brian Atkinson <batkinson@lanl.gov> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Cameron Harr <harr1@llnl.gov> Closes #16008
This commit is contained in:
parent
2ff09e8fed
commit
67995229a8
@ -413,7 +413,7 @@ get_usage(zpool_help_t idx)
|
||||
"[<device> ...]\n"));
|
||||
case HELP_STATUS:
|
||||
return (gettext("\tstatus [--power] [-c [script1,script2,...]] "
|
||||
"[-igLpPstvxD] [-T d|u] [pool] ... \n"
|
||||
"[-DegiLpPstvx] [-T d|u] [pool] ...\n"
|
||||
"\t [interval [count]]\n"));
|
||||
case HELP_UPGRADE:
|
||||
return (gettext("\tupgrade\n"
|
||||
@ -9064,22 +9064,22 @@ status_callback(zpool_handle_t *zhp, void *data)
|
||||
}
|
||||
|
||||
/*
|
||||
* zpool status [-c [script1,script2,...]] [-igLpPstvx] [--power] [-T d|u] ...
|
||||
* zpool status [-c [script1,script2,...]] [-DegiLpPstvx] [--power] [-T d|u] ...
|
||||
* [pool] [interval [count]]
|
||||
*
|
||||
* -c CMD For each vdev, run command CMD
|
||||
* -D Display dedup status (undocumented)
|
||||
* -e Display only unhealthy vdevs
|
||||
* -i Display vdev initialization status.
|
||||
* -g Display guid for individual vdev name.
|
||||
* -i Display vdev initialization status.
|
||||
* -L Follow links when resolving vdev path name.
|
||||
* -p Display values in parsable (exact) format.
|
||||
* -P Display full path for vdev name.
|
||||
* -s Display slow IOs column.
|
||||
* -v Display complete error logs
|
||||
* -x Display only pools with potential problems
|
||||
* -D Display dedup status (undocumented)
|
||||
* -t Display vdev TRIM status.
|
||||
* -T Display a timestamp in date(1) or Unix format
|
||||
* -v Display complete error logs
|
||||
* -x Display only pools with potential problems
|
||||
* --power Display vdev enclosure slot power status
|
||||
*
|
||||
* Describes the health status of all pools or some subset.
|
||||
@ -9100,7 +9100,7 @@ zpool_do_status(int argc, char **argv)
|
||||
};
|
||||
|
||||
/* check options */
|
||||
while ((c = getopt_long(argc, argv, "c:eigLpPsvxDtT:", long_options,
|
||||
while ((c = getopt_long(argc, argv, "c:DegiLpPstT:vx", long_options,
|
||||
NULL)) != -1) {
|
||||
switch (c) {
|
||||
case 'c':
|
||||
@ -9127,15 +9127,18 @@ zpool_do_status(int argc, char **argv)
|
||||
}
|
||||
cmd = optarg;
|
||||
break;
|
||||
case 'D':
|
||||
cb.cb_dedup_stats = B_TRUE;
|
||||
break;
|
||||
case 'e':
|
||||
cb.cb_print_unhealthy = B_TRUE;
|
||||
break;
|
||||
case 'i':
|
||||
cb.cb_print_vdev_init = B_TRUE;
|
||||
break;
|
||||
case 'g':
|
||||
cb.cb_name_flags |= VDEV_NAME_GUID;
|
||||
break;
|
||||
case 'i':
|
||||
cb.cb_print_vdev_init = B_TRUE;
|
||||
break;
|
||||
case 'L':
|
||||
cb.cb_name_flags |= VDEV_NAME_FOLLOW_LINKS;
|
||||
break;
|
||||
@ -9148,21 +9151,18 @@ zpool_do_status(int argc, char **argv)
|
||||
case 's':
|
||||
cb.cb_print_slow_ios = B_TRUE;
|
||||
break;
|
||||
case 'v':
|
||||
cb.cb_verbose = B_TRUE;
|
||||
break;
|
||||
case 'x':
|
||||
cb.cb_explain = B_TRUE;
|
||||
break;
|
||||
case 'D':
|
||||
cb.cb_dedup_stats = B_TRUE;
|
||||
break;
|
||||
case 't':
|
||||
cb.cb_print_vdev_trim = B_TRUE;
|
||||
break;
|
||||
case 'T':
|
||||
get_timestamp_arg(*optarg);
|
||||
break;
|
||||
case 'v':
|
||||
cb.cb_verbose = B_TRUE;
|
||||
break;
|
||||
case 'x':
|
||||
cb.cb_explain = B_TRUE;
|
||||
break;
|
||||
case POWER_OPT:
|
||||
cb.cb_print_power = B_TRUE;
|
||||
break;
|
||||
@ -9202,7 +9202,6 @@ zpool_do_status(int argc, char **argv)
|
||||
|
||||
if (cb.vcdl != NULL)
|
||||
free_vdev_cmd_data_list(cb.vcdl);
|
||||
|
||||
if (argc == 0 && cb.cb_count == 0)
|
||||
(void) fprintf(stderr, gettext("no pools available\n"));
|
||||
else if (cb.cb_explain && cb.cb_first && cb.cb_allpools)
|
||||
|
@ -36,7 +36,7 @@
|
||||
.Sh SYNOPSIS
|
||||
.Nm zpool
|
||||
.Cm status
|
||||
.Op Fl DeigLpPstvx
|
||||
.Op Fl DegiLpPstvx
|
||||
.Op Fl T Sy u Ns | Ns Sy d
|
||||
.Op Fl c Op Ar SCRIPT1 Ns Oo , Ns Ar SCRIPT2 Oc Ns …
|
||||
.Oo Ar pool Oc Ns …
|
||||
@ -69,14 +69,20 @@ See the
|
||||
option of
|
||||
.Nm zpool Cm iostat
|
||||
for complete details.
|
||||
.It Fl D
|
||||
Display a histogram of deduplication statistics, showing the allocated
|
||||
.Pq physically present on disk
|
||||
and referenced
|
||||
.Pq logically referenced in the pool
|
||||
block counts and sizes by reference count.
|
||||
.It Fl e
|
||||
Only show unhealthy vdevs (not-ONLINE or with errors).
|
||||
.It Fl i
|
||||
Display vdev initialization status.
|
||||
.It Fl g
|
||||
Display vdev GUIDs instead of the normal device names
|
||||
These GUIDs can be used in place of device names for the zpool
|
||||
detach/offline/remove/replace commands.
|
||||
.It Fl i
|
||||
Display vdev initialization status.
|
||||
.It Fl L
|
||||
Display real paths for vdevs resolving all symbolic links.
|
||||
This can be used to look up the current block device name regardless of the
|
||||
@ -90,12 +96,6 @@ the path.
|
||||
This can be used in conjunction with the
|
||||
.Fl L
|
||||
flag.
|
||||
.It Fl D
|
||||
Display a histogram of deduplication statistics, showing the allocated
|
||||
.Pq physically present on disk
|
||||
and referenced
|
||||
.Pq logically referenced in the pool
|
||||
block counts and sizes by reference count.
|
||||
.It Fl s
|
||||
Display the number of leaf vdev slow I/O operations.
|
||||
This is the number of I/O operations that didn't complete in
|
||||
|
Loading…
Reference in New Issue
Block a user