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"));
|
"[<device> ...]\n"));
|
||||||
case HELP_STATUS:
|
case HELP_STATUS:
|
||||||
return (gettext("\tstatus [--power] [-c [script1,script2,...]] "
|
return (gettext("\tstatus [--power] [-c [script1,script2,...]] "
|
||||||
"[-igLpPstvxD] [-T d|u] [pool] ... \n"
|
"[-DegiLpPstvx] [-T d|u] [pool] ...\n"
|
||||||
"\t [interval [count]]\n"));
|
"\t [interval [count]]\n"));
|
||||||
case HELP_UPGRADE:
|
case HELP_UPGRADE:
|
||||||
return (gettext("\tupgrade\n"
|
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]]
|
* [pool] [interval [count]]
|
||||||
*
|
*
|
||||||
* -c CMD For each vdev, run command CMD
|
* -c CMD For each vdev, run command CMD
|
||||||
|
* -D Display dedup status (undocumented)
|
||||||
* -e Display only unhealthy vdevs
|
* -e Display only unhealthy vdevs
|
||||||
* -i Display vdev initialization status.
|
|
||||||
* -g Display guid for individual vdev name.
|
* -g Display guid for individual vdev name.
|
||||||
|
* -i Display vdev initialization status.
|
||||||
* -L Follow links when resolving vdev path name.
|
* -L Follow links when resolving vdev path name.
|
||||||
* -p Display values in parsable (exact) format.
|
* -p Display values in parsable (exact) format.
|
||||||
* -P Display full path for vdev name.
|
* -P Display full path for vdev name.
|
||||||
* -s Display slow IOs column.
|
* -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 vdev TRIM status.
|
||||||
* -T Display a timestamp in date(1) or Unix format
|
* -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
|
* --power Display vdev enclosure slot power status
|
||||||
*
|
*
|
||||||
* Describes the health status of all pools or some subset.
|
* Describes the health status of all pools or some subset.
|
||||||
@ -9100,7 +9100,7 @@ zpool_do_status(int argc, char **argv)
|
|||||||
};
|
};
|
||||||
|
|
||||||
/* check options */
|
/* 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) {
|
NULL)) != -1) {
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case 'c':
|
case 'c':
|
||||||
@ -9127,15 +9127,18 @@ zpool_do_status(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
cmd = optarg;
|
cmd = optarg;
|
||||||
break;
|
break;
|
||||||
|
case 'D':
|
||||||
|
cb.cb_dedup_stats = B_TRUE;
|
||||||
|
break;
|
||||||
case 'e':
|
case 'e':
|
||||||
cb.cb_print_unhealthy = B_TRUE;
|
cb.cb_print_unhealthy = B_TRUE;
|
||||||
break;
|
break;
|
||||||
case 'i':
|
|
||||||
cb.cb_print_vdev_init = B_TRUE;
|
|
||||||
break;
|
|
||||||
case 'g':
|
case 'g':
|
||||||
cb.cb_name_flags |= VDEV_NAME_GUID;
|
cb.cb_name_flags |= VDEV_NAME_GUID;
|
||||||
break;
|
break;
|
||||||
|
case 'i':
|
||||||
|
cb.cb_print_vdev_init = B_TRUE;
|
||||||
|
break;
|
||||||
case 'L':
|
case 'L':
|
||||||
cb.cb_name_flags |= VDEV_NAME_FOLLOW_LINKS;
|
cb.cb_name_flags |= VDEV_NAME_FOLLOW_LINKS;
|
||||||
break;
|
break;
|
||||||
@ -9148,21 +9151,18 @@ zpool_do_status(int argc, char **argv)
|
|||||||
case 's':
|
case 's':
|
||||||
cb.cb_print_slow_ios = B_TRUE;
|
cb.cb_print_slow_ios = B_TRUE;
|
||||||
break;
|
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':
|
case 't':
|
||||||
cb.cb_print_vdev_trim = B_TRUE;
|
cb.cb_print_vdev_trim = B_TRUE;
|
||||||
break;
|
break;
|
||||||
case 'T':
|
case 'T':
|
||||||
get_timestamp_arg(*optarg);
|
get_timestamp_arg(*optarg);
|
||||||
break;
|
break;
|
||||||
|
case 'v':
|
||||||
|
cb.cb_verbose = B_TRUE;
|
||||||
|
break;
|
||||||
|
case 'x':
|
||||||
|
cb.cb_explain = B_TRUE;
|
||||||
|
break;
|
||||||
case POWER_OPT:
|
case POWER_OPT:
|
||||||
cb.cb_print_power = B_TRUE;
|
cb.cb_print_power = B_TRUE;
|
||||||
break;
|
break;
|
||||||
@ -9202,7 +9202,6 @@ zpool_do_status(int argc, char **argv)
|
|||||||
|
|
||||||
if (cb.vcdl != NULL)
|
if (cb.vcdl != NULL)
|
||||||
free_vdev_cmd_data_list(cb.vcdl);
|
free_vdev_cmd_data_list(cb.vcdl);
|
||||||
|
|
||||||
if (argc == 0 && cb.cb_count == 0)
|
if (argc == 0 && cb.cb_count == 0)
|
||||||
(void) fprintf(stderr, gettext("no pools available\n"));
|
(void) fprintf(stderr, gettext("no pools available\n"));
|
||||||
else if (cb.cb_explain && cb.cb_first && cb.cb_allpools)
|
else if (cb.cb_explain && cb.cb_first && cb.cb_allpools)
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
.Sh SYNOPSIS
|
.Sh SYNOPSIS
|
||||||
.Nm zpool
|
.Nm zpool
|
||||||
.Cm status
|
.Cm status
|
||||||
.Op Fl DeigLpPstvx
|
.Op Fl DegiLpPstvx
|
||||||
.Op Fl T Sy u Ns | Ns Sy d
|
.Op Fl T Sy u Ns | Ns Sy d
|
||||||
.Op Fl c Op Ar SCRIPT1 Ns Oo , Ns Ar SCRIPT2 Oc Ns …
|
.Op Fl c Op Ar SCRIPT1 Ns Oo , Ns Ar SCRIPT2 Oc Ns …
|
||||||
.Oo Ar pool Oc Ns …
|
.Oo Ar pool Oc Ns …
|
||||||
@ -69,14 +69,20 @@ See the
|
|||||||
option of
|
option of
|
||||||
.Nm zpool Cm iostat
|
.Nm zpool Cm iostat
|
||||||
for complete details.
|
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
|
.It Fl e
|
||||||
Only show unhealthy vdevs (not-ONLINE or with errors).
|
Only show unhealthy vdevs (not-ONLINE or with errors).
|
||||||
.It Fl i
|
|
||||||
Display vdev initialization status.
|
|
||||||
.It Fl g
|
.It Fl g
|
||||||
Display vdev GUIDs instead of the normal device names
|
Display vdev GUIDs instead of the normal device names
|
||||||
These GUIDs can be used in place of device names for the zpool
|
These GUIDs can be used in place of device names for the zpool
|
||||||
detach/offline/remove/replace commands.
|
detach/offline/remove/replace commands.
|
||||||
|
.It Fl i
|
||||||
|
Display vdev initialization status.
|
||||||
.It Fl L
|
.It Fl L
|
||||||
Display real paths for vdevs resolving all symbolic links.
|
Display real paths for vdevs resolving all symbolic links.
|
||||||
This can be used to look up the current block device name regardless of the
|
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
|
This can be used in conjunction with the
|
||||||
.Fl L
|
.Fl L
|
||||||
flag.
|
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
|
.It Fl s
|
||||||
Display the number of leaf vdev slow I/O operations.
|
Display the number of leaf vdev slow I/O operations.
|
||||||
This is the number of I/O operations that didn't complete in
|
This is the number of I/O operations that didn't complete in
|
||||||
|
Loading…
Reference in New Issue
Block a user