zhack.1: modernise

The spacing on zhack    feature stat    pool is a bit iffy(?)

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #12125
This commit is contained in:
наб 2021-05-26 16:46:48 +02:00 committed by Brian Behlendorf
parent 9d7c10388a
commit ea034765b4
1 changed files with 103 additions and 59 deletions

View File

@ -1,4 +1,3 @@
'\" t
.\" .\"
.\" CDDL HEADER START .\" CDDL HEADER START
.\" .\"
@ -19,63 +18,108 @@
.\" .\"
.\" CDDL HEADER END .\" CDDL HEADER END
.\" .\"
.\"
.\" Copyright 2013 Darik Horn <dajhorn@vanadac.com>. All rights reserved. .\" Copyright 2013 Darik Horn <dajhorn@vanadac.com>. All rights reserved.
.\" .\"
.TH ZHACK 1 "Aug 24, 2020" OpenZFS .\" lint-ok: WARNING: sections out of conventional order: Sh SYNOPSIS
.\"
.SH NAME .Dd May 26, 2021
zhack \- libzpool debugging tool .Dt ZHACK 1
.SH DESCRIPTION .Os
.
.Sh NAME
.Nm zhack
.Nd libzpool debugging tool
.Sh DESCRIPTION
This utility pokes configuration changes directly into a ZFS pool, This utility pokes configuration changes directly into a ZFS pool,
which is dangerous and can cause data corruption. which is dangerous and can cause data corruption.
.SH SYNOPSIS .Sh SYNOPSIS
.LP .Bl -tag -width Ds
.BI "zhack [\-c " "cachefile" "] [\-d " "dir" "] <" "subcommand" "> [" "arguments" "]" .It Xo
.SH OPTIONS .Nm zhack
.HP .Cm feature stat
.BI "\-c" " cachefile" .Ar pool
.IP .Xc
Read the \fIpool\fR configuration from the \fIcachefile\fR, which is
/etc/zfs/zpool.cache by default.
.HP
.BI "\-d" " dir"
.IP
Search for \fIpool\fR members in the \fIdir\fR path. Can be specified
more than once.
.SH SUBCOMMANDS
.LP
.BI "feature stat " "pool"
.IP
List feature flags. List feature flags.
.LP .
.BI "feature enable [\-d " "description" "] [\-r] " "pool guid" .It Xo
.IP .Nm zhack
Add a new feature to \fIpool\fR that is uniquely identified by .Cm feature enable
\fIguid\fR, which is specified in the same form as a zfs(8) user .Op Fl d Ar description
property. .Op Fl r
.IP .Ar pool
The \fIdescription\fR is a short human readable explanation of the new .Ar guid
.Xc
Add a new feature to
.Ar pool
that is uniquely identified by
.Ar guid ,
which is specified in the same form as a
.Xr zfs 8
user property.
.Pp
The
.Ar description
is a short human readable explanation of the new feature.
.Pp
The
.Fl r
flag indicates that
.Ar pool
can be safely opened in read-only mode by a system that does not understand the
.Ar guid
feature. feature.
.IP .
The \fB\-r\fR switch indicates that \fIpool\fR can be safely opened .It Xo
in read-only mode by a system that does not have the \fIguid\fR .Nm zhack
feature. .Cm feature ref
.LP .Op Fl d Ns | Ns Fl m
.BI "feature ref [\-d|\-m] " "pool guid" .Ar pool
.IP .Ar guid
Increment the reference count of the \fIguid\fR feature in \fIpool\fR. .Xc
.IP Increment the reference count of the
The \fB\-d\fR switch decrements the reference count of the \fIguid\fR .Ar guid
feature in \fIpool\fR. feature in
.IP .Ar pool .
The \fB\-m\fR switch indicates that the \fIguid\fR feature is now .Pp
required to read the pool MOS. The
.SH EXAMPLES .Fl d
.LP flag decrements the reference count of the
.nf .Ar guid
feature in
.Ar pool
instead.
.Pp
The
.Fl m
flag indicates that the
.Ar guid
feature is now required to read the pool MOS.
.El
.
.Sh GLOBAL OPTIONS
The following can be passed to all
.Nm
invocations before any subcommand:
.Bl -tag -width "-d dir"
.It Fl c Ar cachefile
Read
.Ar pool
configuration from the
.Ar cachefile ,
which is
.Pa /etc/zfs/zpool.cache
by default.
.It Fl d Ar dir
Search for
.Ar pool
members in
.Ar dir .
Can be specified more than once.
.El
.
.Sh EXAMPLES
.Bd -literal
# zhack feature stat tank # zhack feature stat tank
for_read_obj: for_read_obj:
org.illumos:lz4_compress = 0 org.illumos:lz4_compress = 0
for_write_obj: for_write_obj:
@ -85,14 +129,14 @@ descriptions_obj:
com.delphix:async_destroy = Destroy filesystems asynchronously. com.delphix:async_destroy = Destroy filesystems asynchronously.
com.delphix:empty_bpobj = Snapshots use less space. com.delphix:empty_bpobj = Snapshots use less space.
org.illumos:lz4_compress = LZ4 compression algorithm support. org.illumos:lz4_compress = LZ4 compression algorithm support.
.LP
# zhack feature enable -d 'Predict future disk failures.' \\ # zhack feature enable -d 'Predict future disk failures.' \\
tank com.example:clairvoyance tank com.example:clairvoyance
.LP
# zhack feature ref tank com.example:clairvoyance # zhack feature ref tank com.example:clairvoyance
.SH AUTHORS .Ed
This man page was written by Darik Horn <dajhorn@vanadac.com>. .
.SH SEE ALSO .Sh SEE ALSO
.BR zfs (8), .Xr ztest 1 ,
.BR zpool-features (5), .Xr zpool-features 5 ,
.BR ztest (1) .Xr zfs 8