]> granicus.if.org Git - zfs/blob - man/man1/zhack.1
systemd mount generator and tracking ZEDLET
[zfs] / man / man1 / zhack.1
1 '\" t
2 .\"
3 .\" CDDL HEADER START
4 .\"
5 .\" The contents of this file are subject to the terms of the
6 .\" Common Development and Distribution License (the "License").
7 .\" You may not use this file except in compliance with the License.
8 .\"
9 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 .\" or http://www.opensolaris.org/os/licensing.
11 .\" See the License for the specific language governing permissions
12 .\" and limitations under the License.
13 .\"
14 .\" When distributing Covered Code, include this CDDL HEADER in each
15 .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 .\" If applicable, add the following below this CDDL HEADER, with the
17 .\" fields enclosed by brackets "[]" replaced with your own identifying
18 .\" information: Portions Copyright [yyyy] [name of copyright owner]
19 .\"
20 .\" CDDL HEADER END
21 .\"
22 .\"
23 .\" Copyright 2013 Darik Horn <dajhorn@vanadac.com>. All rights reserved.
24 .\"
25 .TH zhack 1 "2013 MAR 16" "ZFS on Linux" "User Commands"
26
27 .SH NAME
28 zhack \- libzpool debugging tool
29 .SH DESCRIPTION
30 This utility pokes configuration changes directly into a ZFS pool,
31 which is dangerous and can cause data corruption.
32 .SH SYNOPSIS
33 .LP
34 .BI "zhack [\-c " "cachefile" "] [\-d " "dir" "] <" "subcommand" "> [" "arguments" "]"
35 .SH OPTIONS
36 .HP
37 .BI "\-c" " cachefile"
38 .IP
39 Read the \fIpool\fR configuration from the \fIcachefile\fR, which is
40 /etc/zfs/zpool.cache by default.
41 .HP
42 .BI "\-d" " dir"
43 .IP
44 Search for \fIpool\fR members in the \fIdir\fR path. Can be specified
45 more than once.
46 .SH SUBCOMMANDS
47 .LP
48 .BI "feature stat " "pool"
49 .IP
50 List feature flags.
51 .LP
52 .BI "feature enable [\-d " "description" "] [\-r] " "pool guid"
53 .IP
54 Add a new feature to \fIpool\fR that is uniquely identified by
55 \fIguid\fR, which is specified in the same form as a zfs(8) user
56 property.
57 .IP
58 The \fIdescription\fR is a short human readable explanation of the new
59 feature.
60 .IP
61 The \fB\-r\fR switch indicates that \fIpool\fR can be safely opened
62 in read-only mode by a system that does not have the \fIguid\fR
63 feature.
64 .LP
65 .BI "feature ref [\-d|\-m] " "pool guid"
66 .IP
67 Increment the reference count of the \fIguid\fR feature in \fIpool\fR.
68 .IP
69 The \fB\-d\fR switch decrements the reference count of the \fIguid\fR
70 feature in \fIpool\fR.
71 .IP
72 The \fB\-m\fR switch indicates that the \fIguid\fR feature is now
73 required to read the pool MOS.
74 .SH EXAMPLES
75 .LP
76 .nf
77 # zhack feature stat tank
78
79 for_read_obj:
80         org.illumos:lz4_compress = 0
81 for_write_obj:
82         com.delphix:async_destroy = 0
83         com.delphix:empty_bpobj = 0
84 descriptions_obj:
85         com.delphix:async_destroy = Destroy filesystems asynchronously.
86         com.delphix:empty_bpobj = Snapshots use less space.
87         org.illumos:lz4_compress = LZ4 compression algorithm support.
88 .LP
89 # zhack feature enable -d 'Predict future disk failures.' \\
90     tank com.example:clairvoyance
91 .LP
92 # zhack feature ref tank com.example:clairvoyance
93 .SH AUTHORS
94 This man page was written by Darik Horn <dajhorn@vanadac.com>.
95 .SH SEE ALSO
96 .BR splat (1),
97 .BR zfs (8),
98 .BR zpool-features (5),
99 .BR ztest (1)