Cleanup various Sun/Solaris-isms
[zfs.git] / man / man8 / zfs.8
1 '\" te
2 .\" Copyright (c) 2009 Sun Microsystems, Inc. All Rights Reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
4 .\"  See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with
5 .\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
7 .\"  See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with
8 .\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
9 .TH zfs 8 "8 Apr 2011" "ZFS pool 28, filesystem 5" "System Administration Commands"
10 .SH NAME
11 zfs \- configures ZFS file systems
12 .SH SYNOPSIS
13 .LP
14 .nf
15 \fBzfs\fR [\fB-?\fR]
16 .fi
17
18 .LP
19 .nf
20 \fBzfs\fR \fBcreate\fR [\fB-p\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fIfilesystem\fR
21 .fi
22
23 .LP
24 .nf
25 \fBzfs\fR \fBcreate\fR [\fB-ps\fR] [\fB-b\fR \fIblocksize\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fB-V\fR \fIsize\fR \fIvolume\fR
26 .fi
27
28 .LP
29 .nf
30 \fBzfs\fR \fBdestroy\fR [\fB-rRf\fR] \fIfilesystem\fR|\fIvolume\fR
31 .fi
32
33 .LP
34 .nf
35 \fBzfs\fR \fBdestroy\fR [\fB-rRd\fR] \fIsnapshot\fR
36 .fi
37
38 .LP
39 .nf
40 \fBzfs\fR \fBsnapshot\fR [\fB-r\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR]... 
41       \fIfilesystem@snapname\fR|\fIvolume@snapname\fR
42 .fi
43
44 .LP
45 .nf
46 \fBzfs\fR \fBrollback\fR [\fB-rRf\fR] \fIsnapshot\fR
47 .fi
48
49 .LP
50 .nf
51 \fBzfs\fR \fBclone\fR [\fB-p\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fIsnapshot\fR \fIfilesystem\fR|\fIvolume\fR
52 .fi
53
54 .LP
55 .nf
56 \fBzfs\fR \fBpromote\fR \fIclone-filesystem\fR
57 .fi
58
59 .LP
60 .nf
61 \fBzfs\fR \fBrename\fR \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR 
62      \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR
63 .fi
64
65 .LP
66 .nf
67 \fBzfs\fR \fBrename\fR [\fB-p\fR] \fIfilesystem\fR|\fIvolume\fR \fIfilesystem\fR|\fIvolume\fR
68 .fi
69
70 .LP
71 .nf
72 \fBzfs\fR \fBrename\fR \fB-r\fR \fIsnapshot\fR \fIsnapshot\fR
73 .fi
74
75 .LP
76 .nf
77 \fBzfs\fR \fBlist\fR [\fB-r\fR|\fB-d\fR \fIdepth\fR][\fB-H\fR][\fB-o\fR \fIproperty\fR[,...]] [\fB-t\fR \fItype\fR[,...]]
78      [\fB-s\fR \fIproperty\fR] ... [\fB-S\fR \fIproperty\fR] ... [\fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR] ...
79 .fi
80
81 .LP
82 .nf
83 \fBzfs\fR \fBset\fR \fIproperty\fR=\fIvalue\fR \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR ...
84 .fi
85
86 .LP
87 .nf
88 \fBzfs\fR \fBget\fR [\fB-r\fR|\fB-d\fR \fIdepth\fR][\fB-Hp\fR][\fB-o\fR \fIfield\fR[,...]] [\fB-s\fR \fIsource\fR[,...]]
89      "\fIall\fR" | \fIproperty\fR[,...] \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR ...
90 .fi
91
92 .LP
93 .nf
94 \fBzfs\fR \fBinherit\fR [\fB-r\fR] \fIproperty\fR \fIfilesystem\fR|\fIvolume|snapshot\fR ...
95 .fi
96
97 .LP
98 .nf
99 \fBzfs\fR \fBupgrade\fR [\fB-v\fR]
100 .fi
101
102 .LP
103 .nf
104 \fBzfs\fR \fBupgrade\fR [\fB-r\fR] [\fB-V\fR \fIversion\fR] \fB-a\fR | \fIfilesystem\fR
105 .fi
106
107 .LP
108 .nf
109 \fBzfs\fR \fBuserspace\fR [\fB-niHp\fR] [\fB-o\fR \fIfield\fR[,...]] [\fB-sS\fR \fIfield\fR] ...
110      [\fB-t\fR \fItype\fR [,...]] \fIfilesystem\fR|\fIsnapshot\fR
111 .fi
112
113 .LP
114 .nf
115 \fBzfs\fR \fBgroupspace\fR [\fB-niHp\fR] [\fB-o\fR \fIfield\fR[,...]] [\fB-sS\fR \fIfield\fR] ...
116      [\fB-t\fR \fItype\fR [,...]] \fIfilesystem\fR|\fIsnapshot\fR
117 .fi
118
119 .LP
120 .nf
121 \fBzfs\fR \fBmount\fR 
122 .fi
123
124 .LP
125 .nf
126 \fBzfs\fR \fBmount\fR [\fB-vO\fR] [\fB-o \fIoptions\fR\fR] \fB-a\fR | \fIfilesystem\fR
127 .fi
128
129 .LP
130 .nf
131 \fBzfs\fR \fBunmount\fR [\fB-f\fR] \fB-a\fR | \fIfilesystem\fR|\fImountpoint\fR
132 .fi
133
134 .LP
135 .nf
136 \fBzfs\fR \fBshare\fR \fB-a\fR | \fIfilesystem\fR
137 .fi
138
139 .LP
140 .nf
141 \fBzfs\fR \fBunshare\fR \fB-a\fR \fIfilesystem\fR|\fImountpoint\fR
142 .fi
143
144 .LP
145 .nf
146 \fBzfs\fR \fBsend\fR [\fB-vR\fR] [\fB-\fR[\fBiI\fR] \fIsnapshot\fR] \fIsnapshot\fR
147 .fi
148
149 .LP
150 .nf
151 \fBzfs\fR \fBreceive\fR [\fB-vnFu\fR] \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR
152 .fi
153
154 .LP
155 .nf
156 \fBzfs\fR \fBreceive\fR [\fB-vnFu\fR] \fB-d\fR \fIfilesystem\fR
157 .fi
158
159 .LP
160 .nf
161 \fBzfs\fR \fBallow\fR \fIfilesystem\fR|\fIvolume\fR
162 .fi
163
164 .LP
165 .nf
166 \fBzfs\fR \fBallow\fR [\fB-ldug\fR] "\fIeveryone\fR"|\fIuser\fR|\fIgroup\fR[,...] \fIperm\fR|\fI@setname\fR[,...] 
167      \fIfilesystem\fR|\fIvolume\fR
168 .fi
169
170 .LP
171 .nf
172 \fBzfs\fR \fBallow\fR [\fB-ld\fR] \fB-e\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR|\fIvolume\fR
173 .fi
174
175 .LP
176 .nf
177 \fBzfs\fR \fBallow\fR \fB-c\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR|\fIvolume\fR
178 .fi
179
180 .LP
181 .nf
182 \fBzfs\fR \fBallow\fR \fB-s\fR @\fIsetname\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR|\fIvolume\fR
183 .fi
184
185 .LP
186 .nf
187 \fBzfs\fR \fBunallow\fR [\fB-rldug\fR] "\fIeveryone\fR"|\fIuser\fR|\fIgroup\fR[,...] [\fIperm\fR|@\fIsetname\fR[,... ]] 
188      \fIfilesystem\fR|\fIvolume\fR
189 .fi
190
191 .LP
192 .nf
193 \fBzfs\fR \fBunallow\fR [\fB-rld\fR] \fB-e\fR [\fIperm\fR|@\fIsetname\fR[,... ]] \fIfilesystem\fR|\fIvolume\fR
194 .fi
195
196 .LP
197 .nf
198 \fBzfs\fR \fBunallow\fR [\fB-r\fR] \fB-c\fR [\fIperm\fR|@\fIsetname\fR[ ... ]] \fIfilesystem\fR|\fIvolume\fR
199 .fi
200
201 .LP
202 .nf
203 \fBzfs\fR \fBunallow\fR [\fB-r\fR] \fB-s\fR @\fIsetname\fR [\fIperm\fR|@\fIsetname\fR[,... ]] \fIfilesystem\fR|\fIvolume\fR
204 .fi
205
206 .LP
207 .nf
208 \fBzfs\fR \fBhold\fR [\fB-r\fR] \fItag\fR \fIsnapshot\fR...
209 .fi
210
211 .LP
212 .nf
213 \fBzfs\fR \fBholds\fR [\fB-r\fR] \fIsnapshot\fR...
214 .fi
215
216 .LP
217 .nf
218 \fBzfs\fR \fBrelease\fR [\fB-r\fR] \fItag\fR \fIsnapshot\fR...
219 .fi
220
221 .SH DESCRIPTION
222 .sp
223 .LP
224 The \fBzfs\fR command configures \fBZFS\fR datasets within a \fBZFS\fR storage pool, as described in \fBzpool\fR(8). A dataset is identified by a unique path within the \fBZFS\fR namespace. For example:
225 .sp
226 .in +2
227 .nf
228 pool/{filesystem,volume,snapshot}
229 .fi
230 .in -2
231 .sp
232
233 .sp
234 .LP
235 where the maximum length of a dataset name is \fBMAXNAMELEN\fR (256 bytes).
236 .sp
237 .LP
238 A dataset can be one of the following:
239 .sp
240 .ne 2
241 .mk
242 .na
243 \fB\fIfile system\fR\fR
244 .ad
245 .sp .6
246 .RS 4n
247 A \fBZFS\fR dataset of type \fBfilesystem\fR can be mounted within the standard system namespace and behaves like other file systems. While \fBZFS\fR file systems are designed to be \fBPOSIX\fR compliant, known issues exist that prevent compliance in some cases. Applications that depend on standards conformance might fail due to nonstandard behavior when checking file system free space.
248 .RE
249
250 .sp
251 .ne 2
252 .mk
253 .na
254 \fB\fIvolume\fR\fR
255 .ad
256 .sp .6
257 .RS 4n
258 A logical volume exported as a raw or block device. This type of dataset should only be used under special circumstances. File systems are typically used in most environments.
259 .RE
260
261 .sp
262 .ne 2
263 .mk
264 .na
265 \fB\fIsnapshot\fR\fR
266 .ad
267 .sp .6
268 .RS 4n
269 A read-only version of a file system or volume at a given point in time. It is specified as \fIfilesystem@name\fR or \fIvolume@name\fR.
270 .RE
271
272 .SS "ZFS File System Hierarchy"
273 .sp
274 .LP
275 A \fBZFS\fR storage pool is a logical collection of devices that provide space for datasets. A storage pool is also the root of the \fBZFS\fR file system hierarchy.
276 .sp
277 .LP
278 The root of the pool can be accessed as a file system, such as mounting and unmounting, taking snapshots, and setting properties. The physical storage characteristics, however, are managed by the \fBzpool\fR(8) command.
279 .sp
280 .LP
281 See \fBzpool\fR(8) for more information on creating and administering pools.
282 .SS "Snapshots"
283 .sp
284 .LP
285 A snapshot is a read-only copy of a file system or volume. Snapshots can be created extremely quickly, and initially consume no additional space within the pool. As data within the active dataset changes, the snapshot consumes more data than would otherwise be shared with the active dataset.
286 .sp
287 .LP
288 Snapshots can have arbitrary names. Snapshots of volumes can be cloned or rolled back, but cannot be accessed independently.
289 .sp
290 .LP
291 File system snapshots can be accessed under the \fB\&.zfs/snapshot\fR directory in the root of the file system. Snapshots are automatically mounted on demand and may be unmounted at regular intervals. The visibility of the \fB\&.zfs\fR directory can be controlled by the \fBsnapdir\fR property.
292 .SS "Clones"
293 .sp
294 .LP
295 A clone is a writable volume or file system whose initial contents are the same as another dataset. As with snapshots, creating a clone is nearly instantaneous, and initially consumes no additional space.
296 .sp
297 .LP
298 Clones can only be created from a snapshot. When a snapshot is cloned, it creates an implicit dependency between the parent and child. Even though the clone is created somewhere else in the dataset hierarchy, the original snapshot cannot be destroyed as long as a clone exists. The \fBorigin\fR property exposes this dependency, and the \fBdestroy\fR command lists any such dependencies, if they exist.
299 .sp
300 .LP
301 The clone parent-child dependency relationship can be reversed by using the \fBpromote\fR subcommand. This causes the "origin" file system to become a clone of the specified file system, which makes it possible to destroy the file system that the clone was created from.
302 .SS "Mount Points"
303 .sp
304 .LP
305 Creating a \fBZFS\fR file system is a simple operation, so the number of file systems per system is likely to be numerous. To cope with this, \fBZFS\fR automatically manages mounting and unmounting file systems without the need to edit the \fB/etc/fstab\fR file. All automatically managed file systems are mounted by \fBZFS\fR at boot time.
306 .sp
307 .LP
308 By default, file systems are mounted under \fB/\fIpath\fR\fR, where \fIpath\fR is the name of the file system in the \fBZFS\fR namespace. Directories are created and destroyed as needed.
309 .sp
310 .LP
311 A file system can also have a mount point set in the \fBmountpoint\fR property. This directory is created as needed, and \fBZFS\fR automatically mounts the file system when the \fBzfs mount -a\fR command is invoked (without editing \fB/etc/fstab\fR). The \fBmountpoint\fR property can be inherited, so if \fBpool/home\fR has a mount point of \fB/export/stuff\fR, then \fBpool/home/user\fR automatically inherits a mount point of \fB/export/stuff/user\fR.
312 .sp
313 .LP
314 A file system \fBmountpoint\fR property of \fBnone\fR prevents the file system from being mounted.
315 .sp
316 .LP
317 If needed, \fBZFS\fR file systems can also be managed with traditional tools (\fBmount\fR, \fBumount\fR, \fB/etc/fstab\fR). If a file system's mount point is set to \fBlegacy\fR, \fBZFS\fR makes no attempt to manage the file system, and the administrator is responsible for mounting and unmounting the file system.
318 .SS "Native Properties"
319 .sp
320 .LP
321 Properties are divided into two types, native properties and user-defined (or "user") properties. Native properties either export internal statistics or control \fBZFS\fR behavior. In addition, native properties are either editable or read-only. User properties have no effect on \fBZFS\fR behavior, but you can use them to annotate datasets in a way that is meaningful in your environment. For more information about user properties, see the "User Properties" section, below.
322 .sp
323 .LP
324 Every dataset has a set of properties that export statistics about the dataset as well as control various behaviors. Properties are inherited from the parent unless overridden by the child. Some properties apply only to certain types of datasets (file systems, volumes, or snapshots).
325 .sp
326 .LP
327 The values of numeric properties can be specified using human-readable suffixes (for example, \fBk\fR, \fBKB\fR, \fBM\fR, \fBGb\fR, and so forth, up to \fBZ\fR for zettabyte). The following are all valid (and equal) specifications: 
328 .sp
329 .in +2
330 .nf
331 1536M, 1.5g, 1.50GB
332 .fi
333 .in -2
334 .sp
335
336 .sp
337 .LP
338 The values of non-numeric properties are case sensitive and must be lowercase, except for \fBmountpoint\fR, \fBsharenfs\fR, and \fBsharesmb\fR.
339 .sp
340 .LP
341 The following native properties consist of read-only statistics about the dataset. These properties can be neither set, nor inherited. Native properties apply to all dataset types unless otherwise noted.
342 .sp
343 .ne 2
344 .mk
345 .na
346 \fB\fBavailable\fR\fR
347 .ad
348 .sp .6
349 .RS 4n
350 The amount of space available to the dataset and all its children, assuming that there is no other activity in the pool. Because space is shared within a pool, availability can be limited by any number of factors, including physical pool size, quotas, reservations, or other datasets within the pool.
351 .sp
352 This property can also be referred to by its shortened column name, \fBavail\fR.
353 .RE
354
355 .sp
356 .ne 2
357 .mk
358 .na
359 \fB\fBcompressratio\fR\fR
360 .ad
361 .sp .6
362 .RS 4n
363 The compression ratio achieved for this dataset, expressed as a multiplier. Compression can be turned on by running: \fBzfs set compression=on \fIdataset\fR\fR. The default value is \fBoff\fR.
364 .RE
365
366 .sp
367 .ne 2
368 .mk
369 .na
370 \fB\fBcreation\fR\fR
371 .ad
372 .sp .6
373 .RS 4n
374 The time this dataset was created.
375 .RE
376
377 .sp
378 .ne 2
379 .mk
380 .na
381 \fB\fBdefer_destroy\fR\fR
382 .ad
383 .sp .6
384 .RS 4n
385 This property is \fBon\fR if the snapshot has been marked for deferred destruction by using the \fBzfs destroy\fR \fB-d\fR command. Otherwise, the property is \fBoff\fR.
386 .RE
387
388 .sp
389 .ne 2
390 .mk
391 .na
392 \fB\fBmounted\fR\fR
393 .ad
394 .sp .6
395 .RS 4n
396 For file systems, indicates whether the file system is currently mounted. This property can be either \fByes\fR or \fBno\fR.
397 .RE
398
399 .sp
400 .ne 2
401 .mk
402 .na
403 \fB\fBorigin\fR\fR
404 .ad
405 .sp .6
406 .RS 4n
407 For cloned file systems or volumes, the snapshot from which the clone was created. The origin cannot be destroyed (even with the \fB-r\fR or \fB-f\fR options) so long as a clone exists.
408 .RE
409
410 .sp
411 .ne 2
412 .mk
413 .na
414 \fB\fBreferenced\fR\fR
415 .ad
416 .sp .6
417 .RS 4n
418 The amount of data that is accessible by this dataset, which may or may not be shared with other datasets in the pool. When a snapshot or clone is created, it initially references the same amount of space as the file system or snapshot it was created from, since its contents are identical.
419 .sp
420 This property can also be referred to by its shortened column name, \fBrefer\fR.
421 .RE
422
423 .sp
424 .ne 2
425 .mk
426 .na
427 \fB\fBtype\fR\fR
428 .ad
429 .sp .6
430 .RS 4n
431 The type of dataset: \fBfilesystem\fR, \fBvolume\fR, or \fBsnapshot\fR.
432 .RE
433
434 .sp
435 .ne 2
436 .mk
437 .na
438 \fB\fBused\fR\fR
439 .ad
440 .sp .6
441 .RS 4n
442 The amount of space consumed by this dataset and all its descendents. This is the value that is checked against this dataset's quota and reservation. The space used does not include this dataset's reservation, but does take into account the reservations of any descendent datasets. The amount of space that a dataset consumes from its parent, as well as the amount of space that are freed if this dataset is recursively destroyed, is the greater of its space used and its reservation.
443 .sp
444 When snapshots (see the "Snapshots" section) are created, their space is initially shared between the snapshot and the file system, and possibly with previous snapshots. As the file system changes, space that was previously shared becomes unique to the snapshot, and counted in the snapshot's space used. Additionally, deleting snapshots can increase the amount of space unique to (and used by) other snapshots.
445 .sp
446 The amount of space used, available, or referenced does not take into account pending changes. Pending changes are generally accounted for within a few seconds. Committing a change to a disk using \fBfsync\fR(2) or \fBO_SYNC\fR does not necessarily guarantee that the space usage information is updated immediately.
447 .RE
448
449 .sp
450 .ne 2
451 .mk
452 .na
453 \fB\fBusedby*\fR\fR
454 .ad
455 .sp .6
456 .RS 4n
457 The \fBusedby*\fR properties decompose the \fBused\fR properties into the various reasons that space is used. Specifically, \fBused\fR = \fBusedbychildren\fR + \fBusedbydataset\fR + \fBusedbyrefreservation\fR +, \fBusedbysnapshots\fR. These properties are only available for datasets created on \fBzpool\fR "version 13" pools.
458 .RE
459
460 .sp
461 .ne 2
462 .mk
463 .na
464 \fB\fBusedbychildren\fR\fR
465 .ad
466 .sp .6
467 .RS 4n
468 The amount of space used by children of this dataset, which would be freed if all the dataset's children were destroyed.
469 .RE
470
471 .sp
472 .ne 2
473 .mk
474 .na
475 \fB\fBusedbydataset\fR\fR
476 .ad
477 .sp .6
478 .RS 4n
479 The amount of space used by this dataset itself, which would be freed if the dataset were destroyed (after first removing any \fBrefreservation\fR and destroying any necessary snapshots or descendents).
480 .RE
481
482 .sp
483 .ne 2
484 .mk
485 .na
486 \fB\fBusedbyrefreservation\fR\fR
487 .ad
488 .sp .6
489 .RS 4n
490 The amount of space used by a \fBrefreservation\fR set on this dataset, which would be freed if the \fBrefreservation\fR was removed.
491 .RE
492
493 .sp
494 .ne 2
495 .mk
496 .na
497 \fB\fBusedbysnapshots\fR\fR
498 .ad
499 .sp .6
500 .RS 4n
501 The amount of space consumed by snapshots of this dataset. In particular, it is the amount of space that would be freed if all of this dataset's snapshots were destroyed. Note that this is not simply the sum of the snapshots' \fBused\fR properties because space can be shared by multiple snapshots.
502 .RE
503
504 .sp
505 .ne 2
506 .mk
507 .na
508 \fB\fBuserused@\fR\fIuser\fR\fR
509 .ad
510 .sp .6
511 .RS 4n
512 The amount of space consumed by the specified user in this dataset. Space is charged to the owner of each file, as displayed by \fBls\fR \fB-l\fR. The amount of space charged is displayed by \fBdu\fR and \fBls\fR \fB-s\fR. See the \fBzfs userspace\fR subcommand for more information.
513 .sp
514 Unprivileged users can access only their own space usage. The root user, or a user who has been granted the \fBuserused\fR privilege with \fBzfs allow\fR, can access everyone's usage.
515 .sp
516 The \fBuserused@\fR... properties are not displayed by \fBzfs get all\fR. The user's name must be appended after the \fB@\fR symbol, using one of the following forms:
517 .RS +4
518 .TP
519 .ie t \(bu
520 .el o
521 \fIPOSIX name\fR (for example, \fBjoe\fR)
522 .RE
523 .RS +4
524 .TP
525 .ie t \(bu
526 .el o
527 \fIPOSIX numeric ID\fR (for example, \fB789\fR)
528 .RE
529 .RS +4
530 .TP
531 .ie t \(bu
532 .el o
533 \fISID name\fR (for example, \fBjoe.smith@mydomain\fR)
534 .RE
535 .RS +4
536 .TP
537 .ie t \(bu
538 .el o
539 \fISID numeric ID\fR (for example, \fBS-1-123-456-789\fR)
540 .RE
541 .RE
542
543 .sp
544 .ne 2
545 .mk
546 .na
547 \fB\fBuserrefs\fR\fR
548 .ad
549 .sp .6
550 .RS 4n
551 This property is set to the number of user holds on this snapshot. User holds are set by using the \fBzfs hold\fR command.
552 .RE
553
554 .sp
555 .ne 2
556 .mk
557 .na
558 \fB\fBgroupused@\fR\fIgroup\fR\fR
559 .ad
560 .sp .6
561 .RS 4n
562 The amount of space consumed by the specified group in this dataset. Space is charged to the group of each file, as displayed by \fBls\fR \fB-l\fR. See the \fBuserused@\fR\fIuser\fR property for more information.
563 .sp
564 Unprivileged users can only access their own groups' space usage. The root user, or a user who has been granted the \fBgroupused\fR privilege with \fBzfs allow\fR, can access all groups' usage.
565 .RE
566
567 .sp
568 .ne 2
569 .mk
570 .na
571 \fB\fBvolblocksize\fR=\fIblocksize\fR\fR
572 .ad
573 .sp .6
574 .RS 4n
575 For volumes, specifies the block size of the volume. The \fBblocksize\fR cannot be changed once the volume has been written, so it should be set at volume creation time. The default \fBblocksize\fR for volumes is 8 Kbytes. Any power of 2 from 512 bytes to 128 Kbytes is valid.
576 .sp
577 This property can also be referred to by its shortened column name, \fBvolblock\fR.
578 .RE
579
580 .sp
581 .LP
582 The following native properties can be used to change the behavior of a \fBZFS\fR dataset.
583 .sp
584 .ne 2
585 .mk
586 .na
587 \fB\fBaclinherit\fR=\fBdiscard\fR | \fBnoallow\fR | \fBrestricted\fR | \fBpassthrough\fR | \fBpassthrough-x\fR\fR
588 .ad
589 .sp .6
590 .RS 4n
591 Controls how \fBACL\fR entries are inherited when files and directories are created. A file system with an \fBaclinherit\fR property of \fBdiscard\fR does not inherit any \fBACL\fR entries. A file system with an \fBaclinherit\fR property value of \fBnoallow\fR only inherits inheritable \fBACL\fR entries that specify "deny" permissions. The property value \fBrestricted\fR (the default) removes the \fBwrite_acl\fR and \fBwrite_owner\fR permissions when the \fBACL\fR entry is inherited. A file system with an \fBaclinherit\fR property value of \fBpassthrough\fR inherits all inheritable \fBACL\fR entries without any modifications made to the \fBACL\fR entries when they are inherited. A file system with an \fBaclinherit\fR property value of \fBpassthrough-x\fR has the same meaning as \fBpassthrough\fR, except that the \fBowner@\fR, \fBgroup@\fR, and \fBeveryone@\fR \fBACE\fRs inherit the execute permission only if the file creation mode also requests the execute bit.
592 .sp
593 When the property value is set to \fBpassthrough\fR, files are created with a mode determined by the inheritable \fBACE\fRs. If no inheritable \fBACE\fRs exist that affect the mode, then the mode is set in accordance to the requested mode from the application.
594 .RE
595
596 .sp
597 .ne 2
598 .mk
599 .na
600 \fB\fBaclmode\fR=\fBdiscard\fR | \fBgroupmask\fR | \fBpassthrough\fR\fR
601 .ad
602 .sp .6
603 .RS 4n
604 Controls how an \fBACL\fR is modified during \fBchmod\fR(2). A file system with an \fBaclmode\fR property of \fBdiscard\fR deletes all \fBACL\fR entries that do not represent the mode of the file. An \fBaclmode\fR property of \fBgroupmask\fR (the default) reduces user or group permissions. The permissions are reduced, such that they are no greater than the group permission bits, unless it is a user entry that has the same \fBUID\fR as the owner of the file or directory. In this case, the \fBACL\fR permissions are reduced so that they are no greater than owner permission bits. A file system with an \fBaclmode\fR property of \fBpassthrough\fR indicates that no changes are made to the \fBACL\fR other than generating the necessary \fBACL\fR entries to represent the new mode of the file or directory.
605 .RE
606
607 .sp
608 .ne 2
609 .mk
610 .na
611 \fB\fBatime\fR=\fBon\fR | \fBoff\fR\fR
612 .ad
613 .sp .6
614 .RS 4n
615 Controls whether the access time for files is updated when they are read. Turning this property off avoids producing write traffic when reading files and can result in significant performance gains, though it might confuse mailers and other similar utilities. The default value is \fBon\fR.
616 .RE
617
618 .sp
619 .ne 2
620 .mk
621 .na
622 \fB\fBcanmount\fR=\fBon\fR | \fBoff\fR | \fBnoauto\fR\fR
623 .ad
624 .sp .6
625 .RS 4n
626 If this property is set to \fBoff\fR, the file system cannot be mounted, and is ignored by \fBzfs mount -a\fR. Setting this property to \fBoff\fR is similar to setting the \fBmountpoint\fR property to \fBnone\fR, except that the dataset still has a normal \fBmountpoint\fR property, which can be inherited. Setting this property to \fBoff\fR allows datasets to be used solely as a mechanism to inherit properties. One example of setting \fBcanmount=\fR\fBoff\fR is to have two datasets with the same \fBmountpoint\fR, so that the children of both datasets appear in the same directory, but might have different inherited characteristics.
627 .sp
628 When the \fBnoauto\fR option is set, a dataset can only be mounted and unmounted explicitly. The dataset is not mounted automatically when the dataset is created or imported, nor is it mounted by the \fBzfs mount -a\fR command or unmounted by the \fBzfs unmount -a\fR command.
629 .sp
630 This property is not inherited.
631 .RE
632
633 .sp
634 .ne 2
635 .mk
636 .na
637 \fB\fBchecksum\fR=\fBon\fR | \fBoff\fR | \fBfletcher2,\fR| \fBfletcher4\fR | \fBsha256\fR\fR
638 .ad
639 .sp .6
640 .RS 4n
641 Controls the checksum used to verify data integrity. The default value is \fBon\fR, which automatically selects an appropriate algorithm (currently, \fBfletcher2\fR, but this may change in future releases). The value \fBoff\fR disables integrity checking on user data. Disabling checksums is \fBNOT\fR a recommended practice.
642 .sp
643 Changing this property affects only newly-written data.
644 .RE
645
646 .sp
647 .ne 2
648 .mk
649 .na
650 \fB\fBcompression\fR=\fBon\fR | \fBoff\fR | \fBlzjb\fR | \fBgzip\fR | \fBgzip-\fR\fIN\fR\fR
651 .ad
652 .sp .6
653 .RS 4n
654 Controls the compression algorithm used for this dataset. The \fBlzjb\fR compression algorithm is optimized for performance while providing decent data compression. Setting compression to \fBon\fR uses the \fBlzjb\fR compression algorithm. The \fBgzip\fR compression algorithm uses the same compression as the \fBgzip\fR(1) command. You can specify the \fBgzip\fR level by using the value \fBgzip-\fR\fIN\fR where \fIN\fR is an integer from 1 (fastest) to 9 (best compression ratio). Currently, \fBgzip\fR is equivalent to \fBgzip-6\fR (which is also the default for \fBgzip\fR(1)).
655 .sp
656 This property can also be referred to by its shortened column name \fBcompress\fR. Changing this property affects only newly-written data.
657 .RE
658
659 .sp
660 .ne 2
661 .mk
662 .na
663 \fB\fBcopies\fR=\fB1\fR | \fB2\fR | \fB3\fR\fR
664 .ad
665 .sp .6
666 .RS 4n
667 Controls the number of copies of data stored for this dataset. These copies are in addition to any redundancy provided by the pool, for example, mirroring or RAID-Z. The copies are stored on different disks, if possible. The space used by multiple copies is charged to the associated file and dataset, changing the \fBused\fR property and counting against quotas and reservations.
668 .sp
669 Changing this property only affects newly-written data. Therefore, set this property at file system creation time by using the \fB-o\fR \fBcopies=\fR\fIN\fR option.
670 .RE
671
672 .sp
673 .ne 2
674 .mk
675 .na
676 \fB\fBdevices\fR=\fBon\fR | \fBoff\fR\fR
677 .ad
678 .sp .6
679 .RS 4n
680 Controls whether device nodes can be opened on this file system. The default value is \fBon\fR.
681 .RE
682
683 .sp
684 .ne 2
685 .mk
686 .na
687 \fB\fBexec\fR=\fBon\fR | \fBoff\fR\fR
688 .ad
689 .sp .6
690 .RS 4n
691 Controls whether processes can be executed from within this file system. The default value is \fBon\fR.
692 .RE
693
694 .sp
695 .ne 2
696 .mk
697 .na
698 \fB\fBmountpoint\fR=\fIpath\fR | \fBnone\fR | \fBlegacy\fR\fR
699 .ad
700 .sp .6
701 .RS 4n
702 Controls the mount point used for this file system. See the "Mount Points" section for more information on how this property is used. 
703 .sp
704 When the \fBmountpoint\fR property is changed for a file system, the file system and any children that inherit the mount point are unmounted. If the new value is \fBlegacy\fR, then they remain unmounted. Otherwise, they are automatically remounted in the new location if the property was previously \fBlegacy\fR or \fBnone\fR, or if they were mounted before the property was changed. In addition, any shared file systems are unshared and shared in the new location.
705 .RE
706
707 .sp
708 .ne 2
709 .mk
710 .na
711 \fB\fBnbmand\fR=\fBon\fR | \fBoff\fR\fR
712 .ad
713 .sp .6
714 .RS 4n
715 Controls whether the file system should be mounted with \fBnbmand\fR (Non Blocking mandatory locks). This is used for \fBCIFS\fR clients. Changes to this property only take effect when the file system is umounted and remounted. See \fBmount\fR(8) for more information on \fBnbmand\fR mounts.
716 .RE
717
718 .sp
719 .ne 2
720 .mk
721 .na
722 \fB\fBprimarycache\fR=\fBall\fR | \fBnone\fR | \fBmetadata\fR\fR
723 .ad
724 .sp .6
725 .RS 4n
726 Controls what is cached in the primary cache (ARC). If this property is set to \fBall\fR, then both user data and metadata is cached. If this property is set to \fBnone\fR, then neither user data nor metadata is cached. If this property is set to \fBmetadata\fR, then only metadata is cached. The default value is \fBall\fR.
727 .RE
728
729 .sp
730 .ne 2
731 .mk
732 .na
733 \fB\fBquota\fR=\fIsize\fR | \fBnone\fR\fR
734 .ad
735 .sp .6
736 .RS 4n
737 Limits the amount of space a dataset and its descendents can consume. This property enforces a hard limit on the amount of space used. This includes all space consumed by descendents, including file systems and snapshots. Setting a quota on a descendent of a dataset that already has a quota does not override the ancestor's quota, but rather imposes an additional limit.
738 .sp
739 Quotas cannot be set on volumes, as the \fBvolsize\fR property acts as an implicit quota.
740 .RE
741
742 .sp
743 .ne 2
744 .mk
745 .na
746 \fB\fBuserquota@\fR\fIuser\fR=\fIsize\fR | \fBnone\fR\fR
747 .ad
748 .sp .6
749 .RS 4n
750 Limits the amount of space consumed by the specified user. User space consumption is identified by the \fBuserspace@\fR\fIuser\fR property.
751 .sp
752 Enforcement of user quotas may be delayed by several seconds. This delay means that a user might exceed their quota before the system notices that they are over quota and begins to refuse additional writes with the \fBEDQUOT\fR error message . See the \fBzfs userspace\fR subcommand for more information.
753 .sp
754 Unprivileged users can only access their own groups' space usage. The root user, or a user who has been granted the \fBuserquota\fR privilege with \fBzfs allow\fR, can get and set everyone's quota.
755 .sp
756 This property is not available on volumes, on file systems before version 4, or on pools before version 15. The \fBuserquota@\fR... properties are not displayed by \fBzfs get all\fR. The user's name must be appended after the \fB@\fR symbol, using one of the following forms:
757 .RS +4
758 .TP
759 .ie t \(bu
760 .el o
761 \fIPOSIX name\fR (for example, \fBjoe\fR)
762 .RE
763 .RS +4
764 .TP
765 .ie t \(bu
766 .el o
767 \fIPOSIX numeric ID\fR (for example, \fB789\fR)
768 .RE
769 .RS +4
770 .TP
771 .ie t \(bu
772 .el o
773 \fISID name\fR (for example, \fBjoe.smith@mydomain\fR)
774 .RE
775 .RS +4
776 .TP
777 .ie t \(bu
778 .el o
779 \fISID numeric ID\fR (for example, \fBS-1-123-456-789\fR)
780 .RE
781 .RE
782
783 .sp
784 .ne 2
785 .mk
786 .na
787 \fB\fBgroupquota@\fR\fIgroup\fR=\fIsize\fR | \fBnone\fR\fR
788 .ad
789 .sp .6
790 .RS 4n
791 Limits the amount of space consumed by the specified group. Group space consumption is identified by the \fBuserquota@\fR\fIuser\fR property.
792 .sp
793 Unprivileged users can access only their own groups' space usage. The root user, or a user who has been granted the \fBgroupquota\fR privilege with \fBzfs allow\fR, can get and set all groups' quotas.
794 .RE
795
796 .sp
797 .ne 2
798 .mk
799 .na
800 \fB\fBreadonly\fR=\fBon\fR | \fBoff\fR\fR
801 .ad
802 .sp .6
803 .RS 4n
804 Controls whether this dataset can be modified. The default value is \fBoff\fR.
805 .sp
806 This property can also be referred to by its shortened column name, \fBrdonly\fR.
807 .RE
808
809 .sp
810 .ne 2
811 .mk
812 .na
813 \fB\fBrecordsize\fR=\fIsize\fR\fR
814 .ad
815 .sp .6
816 .RS 4n
817 Specifies a suggested block size for files in the file system. This property is designed solely for use with database workloads that access files in fixed-size records. \fBZFS\fR automatically tunes block sizes according to internal algorithms optimized for typical access patterns. 
818 .sp
819 For databases that create very large files but access them in small random chunks, these algorithms may be suboptimal. Specifying a \fBrecordsize\fR greater than or equal to the record size of the database can result in significant performance gains. Use of this property for general purpose file systems is strongly discouraged, and may adversely affect performance.
820 .sp
821 The size specified must be a power of two greater than or equal to 512 and less than or equal to 128 Kbytes.
822 .sp
823 Changing the file system's \fBrecordsize\fR affects only files created afterward; existing files are unaffected.
824 .sp
825 This property can also be referred to by its shortened column name, \fBrecsize\fR.
826 .RE
827
828 .sp
829 .ne 2
830 .mk
831 .na
832 \fB\fBrefquota\fR=\fIsize\fR | \fBnone\fR\fR
833 .ad
834 .sp .6
835 .RS 4n
836 Limits the amount of space a dataset can consume. This property enforces a hard limit on the amount of space used. This hard limit does not include space used by descendents, including file systems and snapshots.
837 .RE
838
839 .sp
840 .ne 2
841 .mk
842 .na
843 \fB\fBrefreservation\fR=\fIsize\fR | \fBnone\fR\fR
844 .ad
845 .sp .6
846 .RS 4n
847 The minimum amount of space guaranteed to a dataset, not including its descendents. When the amount of space used is below this value, the dataset is treated as if it were taking up the amount of space specified by \fBrefreservation\fR. The \fBrefreservation\fR reservation is accounted for in the parent datasets' space used, and counts against the parent datasets' quotas and reservations.
848 .sp
849 If \fBrefreservation\fR is set, a snapshot is only allowed if there is enough free pool space outside of this reservation to accommodate the current number of "referenced" bytes in the dataset.
850 .sp
851 This property can also be referred to by its shortened column name, \fBrefreserv\fR.
852 .RE
853
854 .sp
855 .ne 2
856 .mk
857 .na
858 \fB\fBreservation\fR=\fIsize\fR | \fBnone\fR\fR
859 .ad
860 .sp .6
861 .RS 4n
862 The minimum amount of space guaranteed to a dataset and its descendents. When the amount of space used is below this value, the dataset is treated as if it were taking up the amount of space specified by its reservation. Reservations are accounted for in the parent datasets' space used, and count against the parent datasets' quotas and reservations.
863 .sp
864 This property can also be referred to by its shortened column name, \fBreserv\fR.
865 .RE
866
867 .sp
868 .ne 2
869 .mk
870 .na
871 \fB\fBsecondarycache\fR=\fBall\fR | \fBnone\fR | \fBmetadata\fR\fR
872 .ad
873 .sp .6
874 .RS 4n
875 Controls what is cached in the secondary cache (L2ARC). If this property is set to \fBall\fR, then both user data and metadata is cached. If this property is set to \fBnone\fR, then neither user data nor metadata is cached. If this property is set to \fBmetadata\fR, then only metadata is cached. The default value is \fBall\fR.
876 .RE
877
878 .sp
879 .ne 2
880 .mk
881 .na
882 \fB\fBsetuid\fR=\fBon\fR | \fBoff\fR\fR
883 .ad
884 .sp .6
885 .RS 4n
886 Controls whether the set-\fBUID\fR bit is respected for the file system. The default value is \fBon\fR.
887 .RE
888
889 .sp
890 .ne 2
891 .mk
892 .na
893 \fB\fBshareiscsi\fR=\fBon\fR | \fBoff\fR\fR
894 .ad
895 .sp .6
896 .RS 4n
897 Like the \fBsharenfs\fR property, \fBshareiscsi\fR indicates whether a \fBZFS\fR volume is exported as an \fBiSCSI\fR target. The acceptable values for this property are \fBon\fR, \fBoff\fR, and \fBtype=disk\fR. The default value is \fBoff\fR. In the future, other target types might be supported. For example, \fBtape\fR.
898 .sp
899 You might want to set \fBshareiscsi=on\fR for a file system so that all \fBZFS\fR volumes within the file system are shared by default. However, setting this property on a file system has no direct effect.
900 .RE
901
902 .sp
903 .ne 2
904 .mk
905 .na
906 \fB\fBsharesmb\fR=\fBon\fR | \fBoff\fR | \fIopts\fR\fR
907 .ad
908 .sp .6
909 .RS 4n
910 Controls whether the file system is shared by using the Solaris \fBCIFS\fR service, and what options are to be used. A file system with the \fBsharesmb\fR property set to \fBoff\fR is managed through traditional tools such as \fBsharemgr\fR(1M). Otherwise, the file system is automatically shared and unshared with the \fBzfs share\fR and \fBzfs unshare\fR commands. If the property is set to \fBon\fR, the \fBsharemgr\fR(1M) command is invoked with no options. Otherwise, the \fBsharemgr\fR(1M) command is invoked with options equivalent to the contents of this property.
911 .sp
912 Because \fBSMB\fR shares requires a resource name, a unique resource name is constructed from the dataset name. The constructed name is a copy of the dataset name except that the characters in the dataset name, which would be illegal in the resource name, are replaced with underscore (\fB_\fR) characters. A pseudo property "name" is also supported that allows you to replace the data set name with a specified name. The specified name is then used to replace the prefix dataset in the case of inheritance. For example, if the dataset \fBdata/home/john\fR is set to \fBname=john\fR, then \fBdata/home/john\fR has a resource name of \fBjohn\fR. If a child dataset of \fBdata/home/john/backups\fR, it has a resource name of \fBjohn_backups\fR.
913 .sp
914 When SMB shares are created, the SMB share name appears as an entry in the \fB\&.zfs/shares\fR directory. You can use the \fBls\fR or \fBchmod\fR command to display the share-level ACLs on the entries in this directory.
915 .sp
916 When the \fBsharesmb\fR property is changed for a dataset, the dataset and any children inheriting the property are re-shared with the new options, only if the property was previously set to \fBoff\fR, or if they were shared before the property was changed. If the new property is set to \fBoff\fR, the file systems are unshared.
917 .RE
918
919 .sp
920 .ne 2
921 .mk
922 .na
923 \fB\fBsharenfs\fR=\fBon\fR | \fBoff\fR | \fIopts\fR\fR
924 .ad
925 .sp .6
926 .RS 4n
927 Controls whether the file system is shared via \fBNFS\fR, and what options are used. A file system with a \fBsharenfs\fR property of \fBoff\fR is managed through traditional tools such as \fBshare\fR(1M), \fBunshare\fR(1M), and \fBdfstab\fR(4). Otherwise, the file system is automatically shared and unshared with the \fBzfs share\fR and \fBzfs unshare\fR commands. If the property is set to \fBon\fR, the \fBshare\fR(1M) command is invoked with no options. Otherwise, the \fBshare\fR(1M) command is invoked with options equivalent to the contents of this property.
928 .sp
929 When the \fBsharenfs\fR property is changed for a dataset, the dataset and any children inheriting the property are re-shared with the new options, only if the property was previously \fBoff\fR, or if they were shared before the property was changed. If the new property is \fBoff\fR, the file systems are unshared.
930 .RE
931
932 .sp
933 .ne 2
934 .mk
935 .na
936 \fB\fBlogbias\fR = \fBlatency\fR | \fBthroughput\fR\fR
937 .ad
938 .sp .6
939 .RS 4n
940 Provide a hint to ZFS about handling of synchronous requests in this dataset. If \fBlogbias\fR is set to \fBlatency\fR (the default), ZFS will use pool log devices (if configured) to handle the requests at low latency. If \fBlogbias\fR is set to \fBthroughput\fR, ZFS will not use configured pool log devices. ZFS will instead optimize synchronous operations for global pool throughput and efficient use of resources.
941 .RE
942
943 .sp
944 .ne 2
945 .mk
946 .na
947 \fB\fBsnapdir\fR=\fBhidden\fR | \fBvisible\fR\fR
948 .ad
949 .sp .6
950 .RS 4n
951 Controls whether the \fB\&.zfs\fR directory is hidden or visible in the root of the file system as discussed in the "Snapshots" section. The default value is \fBhidden\fR.
952 .RE
953
954 .sp
955 .ne 2
956 .mk
957 .na
958 \fB\fBversion\fR=\fB1\fR | \fB2\fR | \fBcurrent\fR\fR
959 .ad
960 .sp .6
961 .RS 4n
962 The on-disk version of this file system, which is independent of the pool version. This property can only be set to later supported versions. See the \fBzfs upgrade\fR command.
963 .RE
964
965 .sp
966 .ne 2
967 .mk
968 .na
969 \fB\fBvolsize\fR=\fIsize\fR\fR
970 .ad
971 .sp .6
972 .RS 4n
973 For volumes, specifies the logical size of the volume. By default, creating a volume establishes a reservation of equal size. For storage pools with a version number of 9 or higher, a \fBrefreservation\fR is set instead. Any changes to \fBvolsize\fR are reflected in an equivalent change to the reservation (or \fBrefreservation\fR). The \fBvolsize\fR can only be set to a multiple of \fBvolblocksize\fR, and cannot be zero.
974 .sp
975 The reservation is kept equal to the volume's logical size to prevent unexpected behavior for consumers. Without the reservation, the volume could run out of space, resulting in undefined behavior or data corruption, depending on how the volume is used. These effects can also occur when the volume size is changed while it is in use (particularly when shrinking the size). Extreme care should be used when adjusting the volume size.
976 .sp
977 Though not recommended, a "sparse volume" (also known as "thin provisioning") can be created by specifying the \fB-s\fR option to the \fBzfs create -V\fR command, or by changing the reservation after the volume has been created. A "sparse volume" is a volume where the reservation is less then the volume size. Consequently, writes to a sparse volume can fail with \fBENOSPC\fR when the pool is low on space. For a sparse volume, changes to \fBvolsize\fR are not reflected in the reservation.
978 .RE
979
980 .sp
981 .ne 2
982 .mk
983 .na
984 \fB\fBvscan\fR=\fBon\fR | \fBoff\fR\fR
985 .ad
986 .sp .6
987 .RS 4n
988 Controls whether regular files should be scanned for viruses when a file is opened and closed. In addition to enabling this property, the virus scan service must also be enabled for virus scanning to occur. The default value is \fBoff\fR.
989 .RE
990
991 .sp
992 .ne 2
993 .mk
994 .na
995 \fB\fBxattr\fR=\fBon\fR | \fBoff\fR\fR
996 .ad
997 .sp .6
998 .RS 4n
999 Controls whether extended attributes are enabled for this file system. The default value is \fBon\fR.
1000 .RE
1001
1002 .sp
1003 .ne 2
1004 .mk
1005 .na
1006 \fB\fBzoned\fR=\fBon\fR | \fBoff\fR\fR
1007 .ad
1008 .sp .6
1009 .RS 4n
1010 Controls whether the dataset is managed from a non-global zone. Zones are a Solaris feature and are not relevant on Linux. The default value is \fBoff\fR.
1011 .RE
1012
1013 .sp
1014 .LP
1015 The following three properties cannot be changed after the file system is created, and therefore, should be set when the file system is created. If the properties are not set with the \fBzfs create\fR or \fBzpool create\fR commands, these properties are inherited from the parent dataset. If the parent dataset lacks these properties due to having been created prior to these features being supported, the new file system will have the default values for these properties.
1016 .sp
1017 .ne 2
1018 .mk
1019 .na
1020 \fB\fBcasesensitivity\fR=\fBsensitive\fR | \fBinsensitive\fR | \fBmixed\fR\fR
1021 .ad
1022 .sp .6
1023 .RS 4n
1024 Indicates whether the file name matching algorithm used by the file system should be case-sensitive, case-insensitive, or allow a combination of both styles of matching. The default value for the \fBcasesensitivity\fR property is \fBsensitive\fR. Traditionally, UNIX and POSIX file systems have case-sensitive file names.
1025 .sp
1026 The \fBmixed\fR value for the \fBcasesensitivity\fR property indicates that the file system can support requests for both case-sensitive and case-insensitive matching behavior. Currently, case-insensitive matching behavior on a file system that supports mixed behavior is limited to the Solaris CIFS server product. For more information about the \fBmixed\fR value behavior, see the \fISolaris ZFS Administration Guide\fR.
1027 .RE
1028
1029 .sp
1030 .ne 2
1031 .mk
1032 .na
1033 \fB\fBnormalization\fR = \fBnone\fR | \fBformC\fR | \fBformD\fR | \fBformKC\fR | \fBformKD\fR\fR
1034 .ad
1035 .sp .6
1036 .RS 4n
1037 Indicates whether the file system should perform a \fBunicode\fR normalization of file names whenever two file names are compared, and which normalization algorithm should be used. File names are always stored unmodified, names are normalized as part of any comparison process. If this property is set to a legal value other than \fBnone\fR, and the \fButf8only\fR property was left unspecified, the \fButf8only\fR property is automatically set to \fBon\fR. The default value of the \fBnormalization\fR property is \fBnone\fR. This property cannot be changed after the file system is created.
1038 .RE
1039
1040 .sp
1041 .ne 2
1042 .mk
1043 .na
1044 \fB\fButf8only\fR=\fBon\fR | \fBoff\fR\fR
1045 .ad
1046 .sp .6
1047 .RS 4n
1048 Indicates whether the file system should reject file names that include characters that are not present in the \fBUTF-8\fR character code set. If this property is explicitly set to \fBoff\fR, the normalization property must either not be explicitly set or be set to \fBnone\fR. The default value for the \fButf8only\fR property is \fBoff\fR. This property cannot be changed after the file system is created.
1049 .RE
1050
1051 .sp
1052 .LP
1053 The \fBcasesensitivity\fR, \fBnormalization\fR, and \fButf8only\fR properties are also new permissions that can be assigned to non-privileged users by using the \fBZFS\fR delegated administration feature.
1054 .SS "Temporary Mount Point Properties"
1055 .sp
1056 .LP
1057 When a file system is mounted, either through \fBmount\fR(8) for legacy mounts or the \fBzfs mount\fR command for normal file systems, its mount options are set according to its properties. The correlation between properties and mount options is as follows:
1058 .sp
1059 .in +2
1060 .nf
1061     PROPERTY                MOUNT OPTION
1062      devices                 devices/nodevices
1063      exec                    exec/noexec
1064      readonly                ro/rw
1065      setuid                  setuid/nosetuid
1066      xattr                   xattr/noxattr
1067 .fi
1068 .in -2
1069 .sp
1070
1071 .sp
1072 .LP
1073 In addition, these options can be set on a per-mount basis using the \fB-o\fR option, without affecting the property that is stored on disk. The values specified on the command line override the values stored in the dataset. The \fB-nosuid\fR option is an alias for \fBnodevices,nosetuid\fR. These properties are reported as "temporary" by the \fBzfs get\fR command. If the properties are changed while the dataset is mounted, the new setting overrides any temporary settings.
1074 .SS "User Properties"
1075 .sp
1076 .LP
1077 In addition to the standard native properties, \fBZFS\fR supports arbitrary user properties. User properties have no effect on \fBZFS\fR behavior, but applications or administrators can use them to annotate datasets (file systems, volumes, and snapshots).
1078 .sp
1079 .LP
1080 User property names must contain a colon (\fB:\fR) character to distinguish them from native properties. They may contain lowercase letters, numbers, and the following punctuation characters: colon (\fB:\fR), dash (\fB-\fR), period (\fB\&.\fR), and underscore (\fB_\fR). The expected convention is that the property name is divided into two portions such as \fImodule\fR\fB:\fR\fIproperty\fR, but this namespace is not enforced by \fBZFS\fR. User property names can be at most 256 characters, and cannot begin with a dash (\fB-\fR).
1081 .sp
1082 .LP
1083 When making programmatic use of user properties, it is strongly suggested to use a reversed \fBDNS\fR domain name for the \fImodule\fR component of property names to reduce the chance that two independently-developed packages use the same property name for different purposes. For example, property names beginning with \fBcom.sun\fR. are reserved for use by Oracle Corporation (which acquired Sun Microsystems).
1084 .sp
1085 .LP
1086 The values of user properties are arbitrary strings, are always inherited, and are never validated. All of the commands that operate on properties (\fBzfs list\fR, \fBzfs get\fR, \fBzfs set\fR, and so forth) can be used to manipulate both native properties and user properties. Use the \fBzfs inherit\fR command to clear a user property . If the property is not defined in any parent dataset, it is removed entirely. Property values are limited to 1024 characters.
1087 .SS "ZFS Volumes as Swap"
1088 .sp
1089 .LP
1090 Do not swap to a file on a \fBZFS\fR file system. A \fBZFS\fR swap file configuration is not supported.
1091 .SH SUBCOMMANDS
1092 .sp
1093 .LP
1094 All subcommands that modify state are logged persistently to the pool in their original form.
1095 .sp
1096 .ne 2
1097 .mk
1098 .na
1099 \fB\fBzfs ?\fR\fR
1100 .ad
1101 .sp .6
1102 .RS 4n
1103 Displays a help message.
1104 .RE
1105
1106 .sp
1107 .ne 2
1108 .mk
1109 .na
1110 \fB\fBzfs create\fR [\fB-p\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fIfilesystem\fR\fR
1111 .ad
1112 .sp .6
1113 .RS 4n
1114 Creates a new \fBZFS\fR file system. The file system is automatically mounted according to the \fBmountpoint\fR property inherited from the parent.
1115 .sp
1116 .ne 2
1117 .mk
1118 .na
1119 \fB\fB-p\fR\fR
1120 .ad
1121 .sp .6
1122 .RS 4n
1123 Creates all the non-existing parent datasets. Datasets created in this manner are automatically mounted according to the \fBmountpoint\fR property inherited from their parent. Any property specified on the command line using the \fB-o\fR option is ignored. If the target filesystem already exists, the operation completes successfully.
1124 .RE
1125
1126 .sp
1127 .ne 2
1128 .mk
1129 .na
1130 \fB\fB-o\fR \fIproperty\fR=\fIvalue\fR\fR
1131 .ad
1132 .sp .6
1133 .RS 4n
1134 Sets the specified property as if the command \fBzfs set\fR \fIproperty\fR=\fIvalue\fR was invoked at the same time the dataset was created. Any editable \fBZFS\fR property can also be set at creation time. Multiple \fB-o\fR options can be specified. An error results if the same property is specified in multiple \fB-o\fR options.
1135 .RE
1136
1137 .RE
1138
1139 .sp
1140 .ne 2
1141 .mk
1142 .na
1143 \fB\fBzfs create\fR [\fB-ps\fR] [\fB-b\fR \fIblocksize\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fB-V\fR \fIsize\fR \fIvolume\fR\fR
1144 .ad
1145 .sp .6
1146 .RS 4n
1147 Creates a volume of the given size. The volume is exported as a block device in \fB/dev/zvol/\fR\fIpath\fR, where \fIpath\fR is the name of the volume in the \fBZFS\fR namespace. The size represents the logical size as exported by the device. By default, a reservation of equal size is created.
1148 .sp
1149 \fIsize\fR is automatically rounded up to the nearest 128 Kbytes to ensure that the volume has an integral number of blocks regardless of \fIblocksize\fR.
1150 .sp
1151 .ne 2
1152 .mk
1153 .na
1154 \fB\fB-p\fR\fR
1155 .ad
1156 .sp .6
1157 .RS 4n
1158 Creates all the non-existing parent datasets. Datasets created in this manner are automatically mounted according to the \fBmountpoint\fR property inherited from their parent. Any property specified on the command line using the \fB-o\fR option is ignored. If the target filesystem already exists, the operation completes successfully.
1159 .RE
1160
1161 .sp
1162 .ne 2
1163 .mk
1164 .na
1165 \fB\fB-s\fR\fR
1166 .ad
1167 .sp .6
1168 .RS 4n
1169 Creates a sparse volume with no reservation. See \fBvolsize\fR in the Native Properties section for more information about sparse volumes.
1170 .RE
1171
1172 .sp
1173 .ne 2
1174 .mk
1175 .na
1176 \fB\fB-o\fR \fIproperty\fR=\fIvalue\fR\fR
1177 .ad
1178 .sp .6
1179 .RS 4n
1180 Sets the specified property as if the \fBzfs set\fR \fIproperty\fR=\fIvalue\fR command was invoked at the same time the dataset was created. Any editable \fBZFS\fR property can also be set at creation time. Multiple \fB-o\fR options can be specified. An error results if the same property is specified in multiple \fB-o\fR options.
1181 .RE
1182
1183 .sp
1184 .ne 2
1185 .mk
1186 .na
1187 \fB\fB-b\fR \fIblocksize\fR\fR
1188 .ad
1189 .sp .6
1190 .RS 4n
1191 Equivalent to \fB-o\fR \fBvolblocksize\fR=\fIblocksize\fR. If this option is specified in conjunction with \fB-o\fR \fBvolblocksize\fR, the resulting behavior is undefined.
1192 .RE
1193
1194 .RE
1195
1196 .sp
1197 .ne 2
1198 .mk
1199 .na
1200 \fB\fBzfs destroy\fR [\fB-rRf\fR] \fIfilesystem\fR|\fIvolume\fR\fR
1201 .ad
1202 .sp .6
1203 .RS 4n
1204 Destroys the given dataset. By default, the command unshares any file systems that are currently shared, unmounts any file systems that are currently mounted, and refuses to destroy a dataset that has active dependents (children or clones).
1205 .sp
1206 .ne 2
1207 .mk
1208 .na
1209 \fB\fB-r\fR\fR
1210 .ad
1211 .sp .6
1212 .RS 4n
1213 Recursively destroy all children.
1214 .RE
1215
1216 .sp
1217 .ne 2
1218 .mk
1219 .na
1220 \fB\fB-R\fR\fR
1221 .ad
1222 .sp .6
1223 .RS 4n
1224 Recursively destroy all dependents, including cloned file systems outside the target hierarchy.
1225 .RE
1226
1227 .sp
1228 .ne 2
1229 .mk
1230 .na
1231 \fB\fB-f\fR\fR
1232 .ad
1233 .sp .6
1234 .RS 4n
1235 Force an unmount of any file systems using the \fBunmount -f\fR command. This option has no effect on non-file systems or unmounted file systems.
1236 .RE
1237
1238 Extreme care should be taken when applying either the \fB-r\fR or the \fB-f\fR options, as they can destroy large portions of a pool and cause unexpected behavior for mounted file systems in use. 
1239 .RE
1240
1241 .sp
1242 .ne 2
1243 .mk
1244 .na
1245 \fB\fBzfs destroy\fR [\fB-rRd\fR] \fIsnapshot\fR\fR
1246 .ad
1247 .sp .6
1248 .RS 4n
1249 The given snapshot is destroyed immediately if and only if the \fBzfs destroy\fR command without the \fB-d\fR option would have destroyed it. Such immediate destruction would occur, for example, if the snapshot had no clones and the user-initiated reference count were zero.
1250 .sp
1251 If the snapshot does not qualify for immediate destruction, it is marked for deferred destruction. In this state, it exists as a usable, visible snapshot until both of the preconditions listed above are met, at which point it is destroyed.
1252 .sp
1253 .ne 2
1254 .mk
1255 .na
1256 \fB\fB-d\fR\fR
1257 .ad
1258 .sp .6
1259 .RS 4n
1260 Defer snapshot deletion.
1261 .RE
1262
1263 .sp
1264 .ne 2
1265 .mk
1266 .na
1267 \fB\fB-r\fR\fR
1268 .ad
1269 .sp .6
1270 .RS 4n
1271 Destroy (or mark for deferred destruction) all snapshots with this name in descendent file systems.
1272 .RE
1273
1274 .sp
1275 .ne 2
1276 .mk
1277 .na
1278 \fB\fB-R\fR\fR
1279 .ad
1280 .sp .6
1281 .RS 4n
1282 Recursively destroy all dependents.
1283 .RE
1284
1285 .RE
1286
1287 .sp
1288 .ne 2
1289 .mk
1290 .na
1291 \fB\fBzfs snapshot\fR [\fB-r\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fIfilesystem@snapname\fR|\fIvolume@snapname\fR\fR
1292 .ad
1293 .sp .6
1294 .RS 4n
1295 Creates a snapshot with the given name. All previous modifications by successful system calls to the file system are part of the snapshot. See the "Snapshots" section for details.
1296 .sp
1297 .ne 2
1298 .mk
1299 .na
1300 \fB\fB-r\fR\fR
1301 .ad
1302 .sp .6
1303 .RS 4n
1304 Recursively create snapshots of all descendent datasets. Snapshots are taken atomically, so that all recursive snapshots correspond to the same moment in time.
1305 .RE
1306
1307 .sp
1308 .ne 2
1309 .mk
1310 .na
1311 \fB\fB-o\fR \fIproperty\fR=\fIvalue\fR\fR
1312 .ad
1313 .sp .6
1314 .RS 4n
1315 Sets the specified property; see \fBzfs create\fR for details.
1316 .RE
1317
1318 .RE
1319
1320 .sp
1321 .ne 2
1322 .mk
1323 .na
1324 \fB\fBzfs rollback\fR [\fB-rRf\fR] \fIsnapshot\fR\fR
1325 .ad
1326 .sp .6
1327 .RS 4n
1328 Roll back the given dataset to a previous snapshot. When a dataset is rolled back, all data that has changed since the snapshot is discarded, and the dataset reverts to the state at the time of the snapshot. By default, the command refuses to roll back to a snapshot other than the most recent one. In order to do so, all intermediate snapshots must be destroyed by specifying the \fB-r\fR option.
1329 .sp
1330 The \fB-rR\fR options do not recursively destroy the child snapshots of a recursive snapshot. Only the top-level recursive snapshot is destroyed by either of these options. To completely roll back a recursive snapshot, you must rollback the individual child snapshots.
1331 .sp
1332 .ne 2
1333 .mk
1334 .na
1335 \fB\fB-r\fR\fR
1336 .ad
1337 .sp .6
1338 .RS 4n
1339 Recursively destroy any snapshots more recent than the one specified.
1340 .RE
1341
1342 .sp
1343 .ne 2
1344 .mk
1345 .na
1346 \fB\fB-R\fR\fR
1347 .ad
1348 .sp .6
1349 .RS 4n
1350 Recursively destroy any more recent snapshots, as well as any clones of those snapshots.
1351 .RE
1352
1353 .sp
1354 .ne 2
1355 .mk
1356 .na
1357 \fB\fB-f\fR\fR
1358 .ad
1359 .sp .6
1360 .RS 4n
1361 Used with the \fB-R\fR option to force an unmount of any clone file systems that are to be destroyed.
1362 .RE
1363
1364 .RE
1365
1366 .sp
1367 .ne 2
1368 .mk
1369 .na
1370 \fB\fBzfs clone\fR [\fB-p\fR] [\fB-o\fR \fIproperty\fR=\fIvalue\fR] ... \fIsnapshot\fR \fIfilesystem\fR|\fIvolume\fR\fR
1371 .ad
1372 .sp .6
1373 .RS 4n
1374 Creates a clone of the given snapshot. See the "Clones" section for details. The target dataset can be located anywhere in the \fBZFS\fR hierarchy, and is created as the same type as the original.
1375 .sp
1376 .ne 2
1377 .mk
1378 .na
1379 \fB\fB-p\fR\fR
1380 .ad
1381 .sp .6
1382 .RS 4n
1383 Creates all the non-existing parent datasets. Datasets created in this manner are automatically mounted according to the \fBmountpoint\fR property inherited from their parent. If the target filesystem or volume already exists, the operation completes successfully.
1384 .RE
1385
1386 .sp
1387 .ne 2
1388 .mk
1389 .na
1390 \fB\fB-o\fR \fIproperty\fR=\fIvalue\fR\fR
1391 .ad
1392 .sp .6
1393 .RS 4n
1394 Sets the specified property; see \fBzfs create\fR for details.
1395 .RE
1396
1397 .RE
1398
1399 .sp
1400 .ne 2
1401 .mk
1402 .na
1403 \fB\fBzfs promote\fR \fIclone-filesystem\fR\fR
1404 .ad
1405 .sp .6
1406 .RS 4n
1407 Promotes a clone file system to no longer be dependent on its "origin" snapshot. This makes it possible to destroy the file system that the clone was created from. The clone parent-child dependency relationship is reversed, so that the origin file system becomes a clone of the specified file system. 
1408 .sp
1409 The snapshot that was cloned, and any snapshots previous to this snapshot, are now owned by the promoted clone. The space they use moves from the origin file system to the promoted clone, so enough space must be available to accommodate these snapshots. No new space is consumed by this operation, but the space accounting is adjusted. The promoted clone must not have any conflicting snapshot names of its own. The \fBrename\fR subcommand can be used to rename any conflicting snapshots.
1410 .RE
1411
1412 .sp
1413 .ne 2
1414 .mk
1415 .na
1416 \fB\fBzfs rename\fR \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR\fR
1417 .ad
1418 .br
1419 .na
1420 \fB\fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR\fR
1421 .ad
1422 .br
1423 .na
1424 \fB\fBzfs rename\fR [\fB-p\fR] \fIfilesystem\fR|\fIvolume\fR \fIfilesystem\fR|\fIvolume\fR\fR
1425 .ad
1426 .sp .6
1427 .RS 4n
1428 Renames the given dataset. The new target can be located anywhere in the \fBZFS\fR hierarchy, with the exception of snapshots. Snapshots can only be renamed within the parent file system or volume. When renaming a snapshot, the parent file system of the snapshot does not need to be specified as part of the second argument. Renamed file systems can inherit new mount points, in which case they are unmounted and remounted at the new mount point.
1429 .sp
1430 .ne 2
1431 .mk
1432 .na
1433 \fB\fB-p\fR\fR
1434 .ad
1435 .sp .6
1436 .RS 4n
1437 Creates all the nonexistent parent datasets. Datasets created in this manner are automatically mounted according to the \fBmountpoint\fR property inherited from their parent.
1438 .RE
1439
1440 .RE
1441
1442 .sp
1443 .ne 2
1444 .mk
1445 .na
1446 \fB\fBzfs rename\fR \fB-r\fR \fIsnapshot\fR \fIsnapshot\fR\fR
1447 .ad
1448 .sp .6
1449 .RS 4n
1450 Recursively rename the snapshots of all descendent datasets. Snapshots are the only dataset that can be renamed recursively.
1451 .RE
1452
1453 .sp
1454 .ne 2
1455 .mk
1456 .na
1457 \fB\fBzfs\fR \fBlist\fR [\fB-r\fR|\fB-d\fR \fIdepth\fR] [\fB-H\fR] [\fB-o\fR \fIproperty\fR[,\fI\&...\fR]] [ \fB-t\fR \fItype\fR[,\fI\&...\fR]] [ \fB-s\fR \fIproperty\fR ] ... [ \fB-S\fR \fIproperty\fR ] ... [\fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR] ...\fR
1458 .ad
1459 .sp .6
1460 .RS 4n
1461 Lists the property information for the given datasets in tabular form. If specified, you can list property information by the absolute pathname or the relative pathname. By default, all file systems and volumes are displayed. Snapshots are displayed if the \fBlistsnaps\fR property is \fBon\fR (the default is \fBoff\fR) . The following fields are displayed, \fBname,used,available,referenced,mountpoint\fR.
1462 .sp
1463 .ne 2
1464 .mk
1465 .na
1466 \fB\fB-H\fR\fR
1467 .ad
1468 .sp .6
1469 .RS 4n
1470 Used for scripting mode. Do not print headers and separate fields by a single tab instead of arbitrary white space.
1471 .RE
1472
1473 .sp
1474 .ne 2
1475 .mk
1476 .na
1477 \fB\fB-r\fR\fR
1478 .ad
1479 .sp .6
1480 .RS 4n
1481 Recursively display any children of the dataset on the command line. 
1482 .RE
1483
1484 .sp
1485 .ne 2
1486 .mk
1487 .na
1488 \fB\fB-d\fR \fIdepth\fR\fR
1489 .ad
1490 .sp .6
1491 .RS 4n
1492 Recursively display any children of the dataset, limiting the recursion to \fIdepth\fR. A depth of \fB1\fR will display only the dataset and its direct children.
1493 .RE
1494
1495 .sp
1496 .ne 2
1497 .mk
1498 .na
1499 \fB\fB-o\fR \fIproperty\fR\fR
1500 .ad
1501 .sp .6
1502 .RS 4n
1503 A comma-separated list of properties to display. The property must be:
1504 .RS +4
1505 .TP
1506 .ie t \(bu
1507 .el o
1508 One of the properties described in the "Native Properties" section
1509 .RE
1510 .RS +4
1511 .TP
1512 .ie t \(bu
1513 .el o
1514 A user property
1515 .RE
1516 .RS +4
1517 .TP
1518 .ie t \(bu
1519 .el o
1520 The value \fBname\fR to display the dataset name
1521 .RE
1522 .RS +4
1523 .TP
1524 .ie t \(bu
1525 .el o
1526 The value \fBspace\fR to display space usage properties on file systems and volumes. This is a shortcut for specifying \fB-o name,avail,used,usedsnap,usedds,usedrefreserv,usedchild\fR \fB-t filesystem,volume\fR syntax.
1527 .RE
1528 .RE
1529
1530 .sp
1531 .ne 2
1532 .mk
1533 .na
1534 \fB\fB-s\fR \fIproperty\fR\fR
1535 .ad
1536 .sp .6
1537 .RS 4n
1538 A property for sorting the output by column in ascending order based on the value of the property. The property must be one of the properties described in the "Properties" section, or the special value \fBname\fR to sort by the dataset name. Multiple properties can be specified at one time using multiple \fB-s\fR property options. Multiple \fB-s\fR options are evaluated from left to right in decreasing order of importance.
1539 .sp
1540 The following is a list of sorting criteria:
1541 .RS +4
1542 .TP
1543 .ie t \(bu
1544 .el o
1545 Numeric types sort in numeric order.
1546 .RE
1547 .RS +4
1548 .TP
1549 .ie t \(bu
1550 .el o
1551 String types sort in alphabetical order.
1552 .RE
1553 .RS +4
1554 .TP
1555 .ie t \(bu
1556 .el o
1557 Types inappropriate for a row sort that row to the literal bottom, regardless of the specified ordering.
1558 .RE
1559 .RS +4
1560 .TP
1561 .ie t \(bu
1562 .el o
1563 If no sorting options are specified the existing behavior of \fBzfs list\fR is preserved.
1564 .RE
1565 .RE
1566
1567 .sp
1568 .ne 2
1569 .mk
1570 .na
1571 \fB\fB-S\fR \fIproperty\fR\fR
1572 .ad
1573 .sp .6
1574 .RS 4n
1575 Same as the \fB-s\fR option, but sorts by property in descending order. 
1576 .RE
1577
1578 .sp
1579 .ne 2
1580 .mk
1581 .na
1582 \fB\fB-t\fR \fItype\fR\fR
1583 .ad
1584 .sp .6
1585 .RS 4n
1586 A comma-separated list of types to display, where \fItype\fR is one of \fBfilesystem\fR, \fBsnapshot\fR , \fBvolume\fR, or \fBall\fR. For example, specifying \fB-t snapshot\fR displays only snapshots.
1587 .RE
1588
1589 .RE
1590
1591 .sp
1592 .ne 2
1593 .mk
1594 .na
1595 \fB\fBzfs set\fR \fIproperty\fR=\fIvalue\fR \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR ...\fR
1596 .ad
1597 .sp .6
1598 .RS 4n
1599 Sets the property to the given value for each dataset. Only some properties can be edited. See the "Properties" section for more information on what properties can be set and acceptable values. Numeric values can be specified as exact values, or in a human-readable form with a suffix of \fBB\fR, \fBK\fR, \fBM\fR, \fBG\fR, \fBT\fR, \fBP\fR, \fBE\fR, \fBZ\fR (for bytes, kilobytes, megabytes, gigabytes, terabytes, petabytes, exabytes, or zettabytes, respectively). User properties can be set on snapshots. For more information, see the "User Properties" section.
1600 .RE
1601
1602 .sp
1603 .ne 2
1604 .mk
1605 .na
1606 \fB\fBzfs get\fR [\fB-r\fR|\fB-d\fR \fIdepth\fR] [\fB-Hp\fR] [\fB-o\fR \fIfield\fR[,...] [\fB-s\fR \fIsource\fR[,...] "\fIall\fR" | \fIproperty\fR[,...] \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR ...\fR
1607 .ad
1608 .sp .6
1609 .RS 4n
1610 Displays properties for the given datasets. If no datasets are specified, then the command displays properties for all datasets on the system. For each property, the following columns are displayed:
1611 .sp
1612 .in +2
1613 .nf
1614     name      Dataset name
1615      property  Property name
1616      value     Property value
1617      source    Property source. Can either be local, default,
1618                temporary, inherited, or none (-).
1619 .fi
1620 .in -2
1621 .sp
1622
1623 All columns are displayed by default, though this can be controlled by using the \fB-o\fR option. This command takes a comma-separated list of properties as described in the "Native Properties" and "User Properties" sections.
1624 .sp
1625 The special value \fBall\fR can be used to display all properties that apply to the given dataset's type (filesystem, volume, or snapshot).
1626 .sp
1627 .ne 2
1628 .mk
1629 .na
1630 \fB\fB-r\fR\fR
1631 .ad
1632 .sp .6
1633 .RS 4n
1634 Recursively display properties for any children.
1635 .RE
1636
1637 .sp
1638 .ne 2
1639 .mk
1640 .na
1641 \fB\fB-d\fR \fIdepth\fR\fR
1642 .ad
1643 .sp .6
1644 .RS 4n
1645 Recursively display any children of the dataset, limiting the recursion to \fIdepth\fR. A depth of \fB1\fR will display only the dataset and its direct children.
1646 .RE
1647
1648 .sp
1649 .ne 2
1650 .mk
1651 .na
1652 \fB\fB-H\fR\fR
1653 .ad
1654 .sp .6
1655 .RS 4n
1656 Display output in a form more easily parsed by scripts. Any headers are omitted, and fields are explicitly separated by a single tab instead of an arbitrary amount of space.
1657 .RE
1658
1659 .sp
1660 .ne 2
1661 .mk
1662 .na
1663 \fB\fB-o\fR \fIfield\fR\fR
1664 .ad
1665 .sp .6
1666 .RS 4n
1667 A comma-separated list of columns to display. \fBname,property,value,source\fR is the default value. 
1668 .RE
1669
1670 .sp
1671 .ne 2
1672 .mk
1673 .na
1674 \fB\fB-s\fR \fIsource\fR\fR
1675 .ad
1676 .sp .6
1677 .RS 4n
1678 A comma-separated list of sources to display. Those properties coming from a source other than those in this list are ignored. Each source must be one of the following: \fBlocal,default,inherited,temporary,none\fR. The default value is all sources.
1679 .RE
1680
1681 .sp
1682 .ne 2
1683 .mk
1684 .na
1685 \fB\fB-p\fR\fR
1686 .ad
1687 .sp .6
1688 .RS 4n
1689 Display numbers in parseable (exact) values.
1690 .RE
1691
1692 .RE
1693
1694 .sp
1695 .ne 2
1696 .mk
1697 .na
1698 \fB\fBzfs inherit\fR [\fB-r\fR] \fIproperty\fR \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR ...\fR
1699 .ad
1700 .sp .6
1701 .RS 4n
1702 Clears the specified property, causing it to be inherited from an ancestor. If no ancestor has the property set, then the default value is used. See the "Properties" section for a listing of default values, and details on which properties can be inherited.
1703 .sp
1704 .ne 2
1705 .mk
1706 .na
1707 \fB\fB-r\fR\fR
1708 .ad
1709 .sp .6
1710 .RS 4n
1711 Recursively inherit the given property for all children.
1712 .RE
1713
1714 .RE
1715
1716 .sp
1717 .ne 2
1718 .mk
1719 .na
1720 \fB\fBzfs upgrade\fR [\fB-v\fR]\fR
1721 .ad
1722 .sp .6
1723 .RS 4n
1724 Displays a list of file systems that are not the most recent version.
1725 .RE
1726
1727 .sp
1728 .ne 2
1729 .mk
1730 .na
1731 \fB\fBzfs upgrade\fR [\fB-r\fR] [\fB-V\fR \fIversion\fR] [\fB-a\fR | \fIfilesystem\fR]\fR
1732 .ad
1733 .sp .6
1734 .RS 4n
1735 Upgrades file systems to a new on-disk version. Once this is done, the file systems will no longer be accessible on systems running older versions of the software. \fBzfs send\fR streams generated from new snapshots of these file systems cannot be accessed on systems running older versions of the software.
1736 .sp
1737 In general, the file system version is independent of the pool version. See \fBzpool\fR(8) for information on the \fBzpool upgrade\fR command. 
1738 .sp
1739 In some cases, the file system version and the pool version are interrelated and the pool version must be upgraded before the file system version can be upgraded.
1740 .sp
1741 .ne 2
1742 .mk
1743 .na
1744 \fB\fB-a\fR\fR
1745 .ad
1746 .sp .6
1747 .RS 4n
1748 Upgrade all file systems on all imported pools.
1749 .RE
1750
1751 .sp
1752 .ne 2
1753 .mk
1754 .na
1755 \fB\fIfilesystem\fR\fR
1756 .ad
1757 .sp .6
1758 .RS 4n
1759 Upgrade the specified file system. 
1760 .RE
1761
1762 .sp
1763 .ne 2
1764 .mk
1765 .na
1766 \fB\fB-r\fR\fR
1767 .ad
1768 .sp .6
1769 .RS 4n
1770 Upgrade the specified file system and all descendent file systems 
1771 .RE
1772
1773 .sp
1774 .ne 2
1775 .mk
1776 .na
1777 \fB\fB-V\fR \fIversion\fR\fR
1778 .ad
1779 .sp .6
1780 .RS 4n
1781 Upgrade to the specified \fIversion\fR. If the \fB-V\fR flag is not specified, this command upgrades to the most recent version. This option can only be used to increase the version number, and only up to the most recent version supported by this software.
1782 .RE
1783
1784 .RE
1785
1786 .sp
1787 .ne 2
1788 .mk
1789 .na
1790 \fB\fBzfs userspace\fR [\fB-niHp\fR] [\fB-o\fR \fIfield\fR[,...]] [\fB-sS\fR \fIfield\fR]... [\fB-t\fR \fItype\fR [,...]] \fIfilesystem\fR | \fIsnapshot\fR\fR
1791 .ad
1792 .sp .6
1793 .RS 4n
1794 Displays space consumed by, and quotas on, each user in the specified filesystem or snapshot. This corresponds to the \fBuserused@\fR\fIuser\fR and \fBuserquota@\fR\fIuser\fR properties.
1795 .sp
1796 .ne 2
1797 .mk
1798 .na
1799 \fB\fB-n\fR\fR
1800 .ad
1801 .sp .6
1802 .RS 4n
1803 Print numeric ID instead of user/group name.
1804 .RE
1805
1806 .sp
1807 .ne 2
1808 .mk
1809 .na
1810 \fB\fB-H\fR\fR
1811 .ad
1812 .sp .6
1813 .RS 4n
1814 Do not print headers, use tab-delimited output.
1815 .RE
1816
1817 .sp
1818 .ne 2
1819 .mk
1820 .na
1821 \fB\fB-p\fR\fR
1822 .ad
1823 .sp .6
1824 .RS 4n
1825 Use exact (parseable) numeric output.
1826 .RE
1827
1828 .sp
1829 .ne 2
1830 .mk
1831 .na
1832 \fB\fB-o\fR \fIfield\fR[,...]\fR
1833 .ad
1834 .sp .6
1835 .RS 4n
1836 Display only the specified fields from the following set, \fBtype,name,used,quota\fR.The default is to display all fields.
1837 .RE
1838
1839 .sp
1840 .ne 2
1841 .mk
1842 .na
1843 \fB\fB-s\fR \fIfield\fR\fR
1844 .ad
1845 .sp .6
1846 .RS 4n
1847 Sort output by this field. The \fIs\fR and \fIS\fR flags may be specified multiple times to sort first by one field, then by another. The default is \fB-s type\fR \fB-s name\fR.
1848 .RE
1849
1850 .sp
1851 .ne 2
1852 .mk
1853 .na
1854 \fB\fB-S\fR \fIfield\fR\fR
1855 .ad
1856 .sp .6
1857 .RS 4n
1858 Sort by this field in reverse order. See \fB-s\fR.
1859 .RE
1860
1861 .sp
1862 .ne 2
1863 .mk
1864 .na
1865 \fB\fB-t\fR \fItype\fR[,...]\fR
1866 .ad
1867 .sp .6
1868 .RS 4n
1869 Print only the specified types from the following set, \fBall,posixuser,smbuser,posixgroup,smbgroup\fR.
1870 .sp
1871 The default is \fB-t posixuser,smbuser\fR
1872 .sp
1873 The default can be changed to include group types.
1874 .RE
1875
1876 .sp
1877 .ne 2
1878 .mk
1879 .na
1880 \fB\fB-i\fR\fR
1881 .ad
1882 .sp .6
1883 .RS 4n
1884 Translate SID to POSIX ID. The POSIX ID may be ephemeral if no mapping exists. Normal POSIX interfaces (for example, \fBstat\fR(2), \fBls\fR \fB-l\fR) perform this translation, so the \fB-i\fR option allows the output from \fBzfs userspace\fR to be compared directly with those utilities. However, \fB-i\fR may lead to confusion if some files were created by an SMB user before a SMB-to-POSIX name mapping was established. In such a case, some files are owned by the SMB entity and some by the POSIX entity. However, the \fB-i\fR option will report that the POSIX entity has the total usage and quota for both.
1885 .RE
1886
1887 .RE
1888
1889 .sp
1890 .ne 2
1891 .mk
1892 .na
1893 \fB\fBzfs groupspace\fR [\fB-niHp\fR] [\fB-o\fR \fIfield\fR[,...]] [\fB-sS\fR \fIfield\fR]... [\fB-t\fR \fItype\fR [,...]] \fIfilesystem\fR | \fIsnapshot\fR\fR
1894 .ad
1895 .sp .6
1896 .RS 4n
1897 Displays space consumed by, and quotas on, each group in the specified filesystem or snapshot. This subcommand is identical to \fBzfs userspace\fR, except that the default types to display are \fB-t posixgroup,smbgroup\fR.
1898 .sp
1899 .in +2
1900 .nf
1901 -
1902 .fi
1903 .in -2
1904 .sp
1905
1906 .RE
1907
1908 .sp
1909 .ne 2
1910 .mk
1911 .na
1912 \fB\fBzfs mount\fR\fR
1913 .ad
1914 .sp .6
1915 .RS 4n
1916 Displays all \fBZFS\fR file systems currently mounted.
1917 .RE
1918
1919 .sp
1920 .ne 2
1921 .mk
1922 .na
1923 \fB\fBzfs mount\fR [\fB-vO\fR] [\fB-o\fR \fIoptions\fR] \fB-a\fR | \fIfilesystem\fR\fR
1924 .ad
1925 .sp .6
1926 .RS 4n
1927 Mounts \fBZFS\fR file systems. Invoked automatically as part of the boot process.
1928 .sp
1929 .ne 2
1930 .mk
1931 .na
1932 \fB\fB-o\fR \fIoptions\fR\fR
1933 .ad
1934 .sp .6
1935 .RS 4n
1936 An optional, comma-separated list of mount options to use temporarily for the duration of the mount. See the "Temporary Mount Point Properties" section for details.
1937 .RE
1938
1939 .sp
1940 .ne 2
1941 .mk
1942 .na
1943 \fB\fB-O\fR\fR
1944 .ad
1945 .sp .6
1946 .RS 4n
1947 Perform an overlay mount. See \fBmount\fR(8) for more information.
1948 .RE
1949
1950 .sp
1951 .ne 2
1952 .mk
1953 .na
1954 \fB\fB-v\fR\fR
1955 .ad
1956 .sp .6
1957 .RS 4n
1958 Report mount progress.
1959 .RE
1960
1961 .sp
1962 .ne 2
1963 .mk
1964 .na
1965 \fB\fB-a\fR\fR
1966 .ad
1967 .sp .6
1968 .RS 4n
1969 Mount all available \fBZFS\fR file systems. Invoked automatically as part of the boot process. 
1970 .RE
1971
1972 .sp
1973 .ne 2
1974 .mk
1975 .na
1976 \fB\fIfilesystem\fR\fR
1977 .ad
1978 .sp .6
1979 .RS 4n
1980 Mount the specified filesystem.
1981 .RE
1982
1983 .RE
1984
1985 .sp
1986 .ne 2
1987 .mk
1988 .na
1989 \fB\fBzfs unmount\fR [\fB-f\fR] \fB-a\fR | \fIfilesystem\fR|\fImountpoint\fR\fR
1990 .ad
1991 .sp .6
1992 .RS 4n
1993 Unmounts currently mounted \fBZFS\fR file systems. Invoked automatically as part of the shutdown process.
1994 .sp
1995 .ne 2
1996 .mk
1997 .na
1998 \fB\fB-f\fR\fR
1999 .ad
2000 .sp .6
2001 .RS 4n
2002 Forcefully unmount the file system, even if it is currently in use.
2003 .RE
2004
2005 .sp
2006 .ne 2
2007 .mk
2008 .na
2009 \fB\fB-a\fR\fR
2010 .ad
2011 .sp .6
2012 .RS 4n
2013 Unmount all available \fBZFS\fR file systems. Invoked automatically as part of the boot process. 
2014 .RE
2015
2016 .sp
2017 .ne 2
2018 .mk
2019 .na
2020 \fB\fIfilesystem\fR|\fImountpoint\fR\fR
2021 .ad
2022 .sp .6
2023 .RS 4n
2024 Unmount the specified filesystem. The command can also be given a path to a \fBZFS\fR file system mount point on the system.
2025 .RE
2026
2027 .RE
2028
2029 .sp
2030 .ne 2
2031 .mk
2032 .na
2033 \fB\fBzfs share\fR \fB-a\fR | \fIfilesystem\fR\fR
2034 .ad
2035 .sp .6
2036 .RS 4n
2037 Shares available \fBZFS\fR file systems. 
2038 .sp
2039 .ne 2
2040 .mk
2041 .na
2042 \fB\fB-a\fR\fR
2043 .ad
2044 .sp .6
2045 .RS 4n
2046 Share all available \fBZFS\fR file systems. Invoked automatically as part of the boot process. 
2047 .RE
2048
2049 .sp
2050 .ne 2
2051 .mk
2052 .na
2053 \fB\fIfilesystem\fR\fR
2054 .ad
2055 .sp .6
2056 .RS 4n
2057 Share the specified filesystem according to the \fBsharenfs\fR and \fBsharesmb\fR properties. File systems are shared when the \fBsharenfs\fR or \fBsharesmb\fR property is set.
2058 .RE
2059
2060 .RE
2061
2062 .sp
2063 .ne 2
2064 .mk
2065 .na
2066 \fB\fBzfs unshare\fR \fB-a\fR | \fIfilesystem\fR|\fImountpoint\fR\fR
2067 .ad
2068 .sp .6
2069 .RS 4n
2070 Unshares currently shared \fBZFS\fR file systems. This is invoked automatically as part of the shutdown process.
2071 .sp
2072 .ne 2
2073 .mk
2074 .na
2075 \fB\fB-a\fR\fR
2076 .ad
2077 .sp .6
2078 .RS 4n
2079 Unshare all available \fBZFS\fR file systems. Invoked automatically as part of the boot process. 
2080 .RE
2081
2082 .sp
2083 .ne 2
2084 .mk
2085 .na
2086 \fB\fIfilesystem\fR|\fImountpoint\fR\fR
2087 .ad
2088 .sp .6
2089 .RS 4n
2090 Unshare the specified filesystem. The command can also be given a path to a \fBZFS\fR file system shared on the system.
2091 .RE
2092
2093 .RE
2094
2095 .sp
2096 .ne 2
2097 .mk
2098 .na
2099 \fB\fBzfs send\fR [\fB-vR\fR] [\fB-\fR[\fBiI\fR] \fIsnapshot\fR] \fIsnapshot\fR\fR
2100 .ad
2101 .sp .6
2102 .RS 4n
2103 Creates a stream representation of the second \fIsnapshot\fR, which is written to standard output. The output can be redirected to a file or to a different system (for example, using \fBssh\fR(1). By default, a full stream is generated.
2104 .sp
2105 .ne 2
2106 .mk
2107 .na
2108 \fB\fB-i\fR \fIsnapshot\fR\fR
2109 .ad
2110 .sp .6
2111 .RS 4n
2112 Generate an incremental stream from the first \fIsnapshot\fR to the second \fIsnapshot\fR. The incremental source (the first \fIsnapshot\fR) can be specified as the last component of the snapshot name (for example, the part after the \fB@\fR), and it is assumed to be from the same file system as the second \fIsnapshot\fR.
2113 .sp
2114 If the destination is a clone, the source may be the origin snapshot, which must be fully specified (for example, \fBpool/fs@origin\fR, not just \fB@origin\fR).
2115 .RE
2116
2117 .sp
2118 .ne 2
2119 .mk
2120 .na
2121 \fB\fB-I\fR \fIsnapshot\fR\fR
2122 .ad
2123 .sp .6
2124 .RS 4n
2125 Generate a stream package that sends all intermediary snapshots from the first snapshot to the second snapshot. For example, \fB-I @a fs@d\fR is similar to \fB-i @a fs@b; -i @b fs@c; -i @c fs@d\fR. The incremental source snapshot may be specified as with the \fB-i\fR option.
2126 .RE
2127
2128 .sp
2129 .ne 2
2130 .mk
2131 .na
2132 \fB\fB-R\fR\fR
2133 .ad
2134 .sp .6
2135 .RS 4n
2136 Generate a replication stream package, which will replicate the specified filesystem, and all descendent file systems, up to the named snapshot. When received, all properties, snapshots, descendent file systems, and clones are preserved.
2137 .sp
2138 If the \fB-i\fR or \fB-I\fR flags are used in conjunction with the \fB-R\fR flag, an incremental replication stream is generated. The current values of properties, and current snapshot and file system names are set when the stream is received. If the \fB-F\fR flag is specified when this stream is received, snapshots and file systems that do not exist on the sending side are destroyed. 
2139 .RE
2140
2141 .sp
2142 .ne 2
2143 .mk
2144 .na
2145 \fB\fB-v\fR\fR
2146 .ad
2147 .sp .6
2148 .RS 4n
2149 Print verbose information about the stream package generated.
2150 .RE
2151
2152 The format of the stream is committed. You will be able to receive your streams on future versions of \fBZFS\fR.
2153 .RE
2154
2155 .sp
2156 .ne 2
2157 .mk
2158 .na
2159 \fB\fBzfs receive\fR [\fB-vnFu\fR] \fIfilesystem\fR|\fIvolume\fR|\fIsnapshot\fR\fR
2160 .ad
2161 .br
2162 .na
2163 \fB\fBzfs receive\fR [\fB-vnFu\fR] \fB-d\fR \fIfilesystem\fR\fR
2164 .ad
2165 .sp .6
2166 .RS 4n
2167 Creates a snapshot whose contents are as specified in the stream provided on standard input. If a full stream is received, then a new file system is created as well. Streams are created using the \fBzfs send\fR subcommand, which by default creates a full stream. \fBzfs recv\fR can be used as an alias for \fBzfs receive\fR.
2168 .sp
2169 If an incremental stream is received, then the destination file system must already exist, and its most recent snapshot must match the incremental stream's source. For \fBzvols\fR, the destination device link is destroyed and recreated, which means the \fBzvol\fR cannot be accessed during the \fBreceive\fR operation.
2170 .sp
2171 When a snapshot replication package stream that is generated by using the \fBzfs send\fR \fB-R\fR command is  received, any snapshots that do not exist on the sending location are destroyed by using the \fBzfs destroy\fR \fB-d\fR command.
2172 .sp
2173 The name of the snapshot (and file system, if a full stream is received) that this subcommand creates depends on the argument type and the \fB-d\fR option.
2174 .sp
2175 If the argument is a snapshot name, the specified \fIsnapshot\fR is created. If the argument is a file system or volume name, a snapshot with the same name as the sent snapshot is created within the specified \fIfilesystem\fR or \fIvolume\fR. If the \fB-d\fR option is specified, the snapshot name is determined by appending the sent snapshot's name to the specified \fIfilesystem\fR. If the \fB-d\fR option is specified, any required file systems within the specified one are created.
2176 .sp
2177 .ne 2
2178 .mk
2179 .na
2180 \fB\fB-d\fR\fR
2181 .ad
2182 .sp .6
2183 .RS 4n
2184 Use the name of the sent snapshot to determine the name of the new snapshot as described in the paragraph above.
2185 .RE
2186
2187 .sp
2188 .ne 2
2189 .mk
2190 .na
2191 \fB\fB-u\fR\fR
2192 .ad
2193 .sp .6
2194 .RS 4n
2195 File system that is associated with the received stream is not mounted.
2196 .RE
2197
2198 .sp
2199 .ne 2
2200 .mk
2201 .na
2202 \fB\fB-v\fR\fR
2203 .ad
2204 .sp .6
2205 .RS 4n
2206 Print verbose information about the stream and the time required to perform the receive operation.
2207 .RE
2208
2209 .sp
2210 .ne 2
2211 .mk
2212 .na
2213 \fB\fB-n\fR\fR
2214 .ad
2215 .sp .6
2216 .RS 4n
2217 Do not actually receive the stream. This can be useful in conjunction with the \fB-v\fR option to verify the name the receive operation would use.
2218 .RE
2219
2220 .sp
2221 .ne 2
2222 .mk
2223 .na
2224 \fB\fB-F\fR\fR
2225 .ad
2226 .sp .6
2227 .RS 4n
2228 Force a rollback of the file system to the most recent snapshot before performing the receive operation. If receiving an incremental replication stream (for example, one generated by \fBzfs send -R -[iI]\fR), destroy snapshots and file systems that do not exist on the sending side.
2229 .RE
2230
2231 .RE
2232
2233 .sp
2234 .ne 2
2235 .mk
2236 .na
2237 \fB\fBzfs allow\fR \fIfilesystem\fR | \fIvolume\fR\fR
2238 .ad
2239 .sp .6
2240 .RS 4n
2241 Displays permissions that have been delegated on the specified filesystem or volume. See the other forms of \fBzfs allow\fR for more information.
2242 .RE
2243
2244 .sp
2245 .ne 2
2246 .mk
2247 .na
2248 \fB\fBzfs allow\fR [\fB-ldug\fR] "\fIeveryone\fR"|\fIuser\fR|\fIgroup\fR[,...] \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR| \fIvolume\fR\fR
2249 .ad
2250 .br
2251 .na
2252 \fB\fBzfs allow\fR [\fB-ld\fR] \fB-e\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR | \fIvolume\fR\fR
2253 .ad
2254 .sp .6
2255 .RS 4n
2256 Delegates \fBZFS\fR administration permission for the file systems to non-privileged users.
2257 .sp
2258 .ne 2
2259 .mk
2260 .na
2261 \fB[\fB-ug\fR] "\fIeveryone\fR"|\fIuser\fR|\fIgroup\fR[,...]\fR
2262 .ad
2263 .sp .6
2264 .RS 4n
2265 Specifies to whom the permissions are delegated. Multiple entities can be specified as a comma-separated list. If neither of the \fB-ug\fR options are specified, then the argument is interpreted preferentially as the keyword "everyone", then as a user name, and lastly as a group name. To specify a user or group named "everyone", use the \fB-u\fR or \fB-g\fR options. To specify a group with the same name as a user, use the \fB-g\fR options.
2266 .RE
2267
2268 .sp
2269 .ne 2
2270 .mk
2271 .na
2272 \fB[\fB-e\fR] \fIperm\fR|@\fIsetname\fR[,...]\fR
2273 .ad
2274 .sp .6
2275 .RS 4n
2276 Specifies that the permissions be delegated to "everyone." Multiple permissions may be specified as a comma-separated list. Permission names are the same as \fBZFS\fR subcommand and property names. See the property list below. Property set names, which begin with an at sign (\fB@\fR) , may be specified. See the \fB-s\fR form below for details.
2277 .RE
2278
2279 .sp
2280 .ne 2
2281 .mk
2282 .na
2283 \fB[\fB-ld\fR] \fIfilesystem\fR|\fIvolume\fR\fR
2284 .ad
2285 .sp .6
2286 .RS 4n
2287 Specifies where the permissions are delegated. If neither of the \fB-ld\fR options are specified, or both are, then the permissions are allowed for the file system or volume, and all of its descendents. If only the \fB-l\fR option is used, then is allowed "locally" only for the specified file system. If only the \fB-d\fR option is used, then is allowed only for the descendent file systems.
2288 .RE
2289
2290 .RE
2291
2292 .sp
2293 .LP
2294 Permissions are generally the ability to use a \fBZFS\fR subcommand or change a \fBZFS\fR property. The following permissions are available:
2295 .sp
2296 .in +2
2297 .nf
2298 NAME             TYPE           NOTES
2299 allow            subcommand     Must also have the permission that is being
2300                                 allowed
2301 clone            subcommand     Must also have the 'create' ability and 'mount'
2302                                 ability in the origin file system
2303 create           subcommand     Must also have the 'mount' ability
2304 destroy          subcommand     Must also have the 'mount' ability
2305 mount            subcommand     Allows mount/umount of ZFS datasets
2306 promote          subcommand     Must also have the 'mount'
2307                                 and 'promote' ability in the origin file system
2308 receive          subcommand     Must also have the 'mount' and 'create' ability
2309 rename           subcommand     Must also have the 'mount' and 'create'
2310                                 ability in the new parent
2311 rollback         subcommand     Must also have the 'mount' ability
2312 send             subcommand     
2313 share            subcommand     Allows sharing file systems over NFS or SMB
2314                                 protocols
2315 snapshot         subcommand     Must also have the 'mount' ability
2316 groupquota       other          Allows accessing any groupquota@... property
2317 groupused        other          Allows reading any groupused@... property
2318 userprop         other          Allows changing any user property
2319 userquota        other          Allows accessing any userquota@... property
2320 userused         other          Allows reading any userused@... property
2321
2322 aclinherit       property       
2323 aclmode          property       
2324 atime            property       
2325 canmount         property       
2326 casesensitivity  property       
2327 checksum         property       
2328 compression      property       
2329 copies           property       
2330 devices          property       
2331 exec             property       
2332 mountpoint       property       
2333 nbmand           property       
2334 normalization    property       
2335 primarycache     property       
2336 quota            property       
2337 readonly         property       
2338 recordsize       property       
2339 refquota         property       
2340 refreservation   property       
2341 reservation      property       
2342 secondarycache   property       
2343 setuid           property       
2344 shareiscsi       property       
2345 sharenfs         property       
2346 sharesmb         property       
2347 snapdir          property       
2348 utf8only         property       
2349 version          property       
2350 volblocksize     property       
2351 volsize          property       
2352 vscan            property       
2353 xattr            property       
2354 zoned            property       
2355 .fi
2356 .in -2
2357 .sp
2358
2359 .sp
2360 .ne 2
2361 .mk
2362 .na
2363 \fB\fBzfs allow\fR \fB-c\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR|\fIvolume\fR\fR
2364 .ad
2365 .sp .6
2366 .RS 4n
2367 Sets "create time" permissions. These permissions are granted (locally) to the creator of any newly-created descendent file system.
2368 .RE
2369
2370 .sp
2371 .ne 2
2372 .mk
2373 .na
2374 \fB\fBzfs allow\fR \fB-s\fR @\fIsetname\fR \fIperm\fR|@\fIsetname\fR[,...] \fIfilesystem\fR|\fIvolume\fR\fR
2375 .ad
2376 .sp .6
2377 .RS 4n
2378 Defines or adds permissions to a permission set. The set can be used by other \fBzfs allow\fR commands for the specified file system and its descendents. Sets are evaluated dynamically, so changes to a set are immediately reflected. Permission sets follow the same naming restrictions as ZFS file systems, but the name must begin with an "at sign" (\fB@\fR), and can be no more than 64 characters long.
2379 .RE
2380
2381 .sp
2382 .ne 2
2383 .mk
2384 .na
2385 \fB\fBzfs unallow\fR [\fB-rldug\fR] "\fIeveryone\fR"|\fIuser\fR|\fIgroup\fR[,...] [\fIperm\fR|@\fIsetname\fR[, ...]] \fIfilesystem\fR|\fIvolume\fR\fR
2386 .ad
2387 .br
2388 .na
2389 \fB\fBzfs unallow\fR [\fB-rld\fR] \fB-e\fR [\fIperm\fR|@\fIsetname\fR [,...]] \fIfilesystem\fR|\fIvolume\fR\fR
2390 .ad
2391 .br
2392 .na
2393 \fB\fBzfs unallow\fR [\fB-r\fR] \fB-c\fR [\fIperm\fR|@\fIsetname\fR[,...]]\fR
2394 .ad
2395 .br
2396 .na
2397 \fB\fIfilesystem\fR|\fIvolume\fR\fR
2398 .ad
2399 .sp .6
2400 .RS 4n
2401 Removes permissions that were granted with the \fBzfs allow\fR command. No permissions are explicitly denied, so other permissions granted are still in effect. For example, if the permission is granted by an ancestor. If no permissions are specified, then all permissions for the specified \fIuser\fR, \fIgroup\fR, or \fIeveryone\fR are removed. Specifying "everyone" (or using the \fB-e\fR option) only removes the permissions that were granted to "everyone", not all permissions for every user and group. See the \fBzfs allow\fR command for a description of the \fB-ldugec\fR options.
2402 .sp
2403 .ne 2
2404 .mk
2405 .na
2406 \fB\fB-r\fR\fR
2407 .ad
2408 .sp .6
2409 .RS 4n
2410 Recursively remove the permissions from this file system and all descendents.
2411 .RE
2412
2413 .RE
2414
2415 .sp
2416 .ne 2
2417 .mk
2418 .na
2419 \fB\fBzfs unallow\fR [\fB-r\fR] \fB-s\fR @\fIsetname\fR [\fIperm\fR|@\fIsetname\fR[,...]]\fR
2420 .ad
2421 .br
2422 .na
2423 \fB\fIfilesystem\fR|\fIvolume\fR\fR
2424 .ad
2425 .sp .6
2426 .RS 4n
2427 Removes permissions from a permission set. If no permissions are specified, then all permissions are removed, thus removing the set entirely.
2428 .RE
2429
2430 .sp
2431 .ne 2
2432 .mk
2433 .na
2434 \fB\fBzfs hold\fR [\fB-r\fR] \fItag\fR \fIsnapshot\fR...\fR
2435 .ad
2436 .sp .6
2437 .RS 4n
2438 Adds a single reference, named with the \fItag\fR argument, to the specified snapshot or snapshots. Each snapshot has its own tag namespace, and tags must be unique within that space.
2439 .sp
2440 If a hold exists on a snapshot, attempts to destroy that snapshot by using the \fBzfs destroy\fR command return \fBEBUSY\fR.
2441 .sp
2442 .ne 2
2443 .mk
2444 .na
2445 \fB\fB-r\fR\fR
2446 .ad
2447 .sp .6
2448 .RS 4n
2449 Specifies that a hold with the given tag is applied recursively to the snapshots of all descendent file systems.
2450 .RE
2451
2452 .RE
2453
2454 .sp
2455 .ne 2
2456 .mk
2457 .na
2458 \fB\fBzfs holds\fR [\fB-r\fR] \fIsnapshot\fR...\fR
2459 .ad
2460 .sp .6
2461 .RS 4n
2462 Lists all existing user references for the given snapshot or snapshots.
2463 .sp
2464 .ne 2
2465 .mk
2466 .na
2467 \fB\fB-r\fR\fR
2468 .ad
2469 .sp .6
2470 .RS 4n
2471 Lists the holds that are set on the named descendent snapshots, in addition to listing the holds on the named snapshot.
2472 .RE
2473
2474 .RE
2475
2476 .sp
2477 .ne 2
2478 .mk
2479 .na
2480 \fB\fBzfs release\fR [\fB-r\fR] \fItag\fR \fIsnapshot\fR...\fR
2481 .ad
2482 .sp .6
2483 .RS 4n
2484 Removes a single reference, named with the \fItag\fR argument, from the specified snapshot or snapshots. The tag must already exist for each snapshot.
2485 .sp
2486 If a hold exists on a snapshot, attempts to destroy that snapshot by using the \fBzfs destroy\fR command return \fBEBUSY\fR.
2487 .sp
2488 .ne 2
2489 .mk
2490 .na
2491 \fB\fB-r\fR\fR
2492 .ad
2493 .sp .6
2494 .RS 4n
2495 Recursively releases a hold with the given tag on the snapshots of all descendent file systems.
2496 .RE
2497
2498 .RE
2499
2500 .SH EXAMPLES
2501 .LP
2502 \fBExample 1 \fRCreating a ZFS File System Hierarchy
2503 .sp
2504 .LP
2505 The following commands create a file system named \fBpool/home\fR and a file system named \fBpool/home/bob\fR. The mount point \fB/export/home\fR is set for the parent file system, and is automatically inherited by the child file system.
2506
2507 .sp
2508 .in +2
2509 .nf
2510 # \fBzfs create pool/home\fR
2511 # \fBzfs set mountpoint=/export/home pool/home\fR
2512 # \fBzfs create pool/home/bob\fR
2513 .fi
2514 .in -2
2515 .sp
2516
2517 .LP
2518 \fBExample 2 \fRCreating a ZFS Snapshot
2519 .sp
2520 .LP
2521 The following command creates a snapshot named \fByesterday\fR. This snapshot is mounted on demand in the \fB\&.zfs/snapshot\fR directory at the root of the \fBpool/home/bob\fR file system.
2522
2523 .sp
2524 .in +2
2525 .nf
2526 # \fBzfs snapshot pool/home/bob@yesterday\fR
2527 .fi
2528 .in -2
2529 .sp
2530
2531 .LP
2532 \fBExample 3 \fRCreating and Destroying Multiple Snapshots
2533 .sp
2534 .LP
2535 The following command creates snapshots named \fByesterday\fR of \fBpool/home\fR and all of its descendent file systems. Each snapshot is mounted on demand in the \fB\&.zfs/snapshot\fR directory at the root of its file system. The second command destroys the newly created snapshots.
2536
2537 .sp
2538 .in +2
2539 .nf
2540 # \fBzfs snapshot -r pool/home@yesterday\fR
2541 # \fBzfs destroy -r pool/home@yesterday\fR
2542 .fi
2543 .in -2
2544 .sp
2545
2546 .LP
2547 \fBExample 4 \fRDisabling and Enabling File System Compression
2548 .sp
2549 .LP
2550 The following command disables the \fBcompression\fR property for all file systems under \fBpool/home\fR. The next command explicitly enables \fBcompression\fR for \fBpool/home/anne\fR.
2551
2552 .sp
2553 .in +2
2554 .nf
2555 # \fBzfs set compression=off pool/home\fR
2556 # \fBzfs set compression=on pool/home/anne\fR
2557 .fi
2558 .in -2
2559 .sp
2560
2561 .LP
2562 \fBExample 5 \fRListing ZFS Datasets
2563 .sp
2564 .LP
2565 The following command lists all active file systems and volumes in the system. Snapshots are displayed if the \fBlistsnaps\fR property is \fBon\fR. The default is \fBoff\fR. See \fBzpool\fR(8) for more information on pool properties.
2566
2567 .sp
2568 .in +2
2569 .nf
2570 # \fBzfs list\fR
2571    NAME                      USED  AVAIL  REFER  MOUNTPOINT
2572    pool                      450K   457G    18K  /pool
2573    pool/home                 315K   457G    21K  /export/home
2574    pool/home/anne             18K   457G    18K  /export/home/anne
2575    pool/home/bob             276K   457G   276K  /export/home/bob
2576 .fi
2577 .in -2
2578 .sp
2579
2580 .LP
2581 \fBExample 6 \fRSetting a Quota on a ZFS File System
2582 .sp
2583 .LP
2584 The following command sets a quota of 50 Gbytes for \fBpool/home/bob\fR.
2585
2586 .sp
2587 .in +2
2588 .nf
2589 # \fBzfs set quota=50G pool/home/bob\fR
2590 .fi
2591 .in -2
2592 .sp
2593
2594 .LP
2595 \fBExample 7 \fRListing ZFS Properties
2596 .sp
2597 .LP
2598 The following command lists all properties for \fBpool/home/bob\fR.
2599
2600 .sp
2601 .in +2
2602 .nf
2603 # \fBzfs get all pool/home/bob\fR
2604 NAME           PROPERTY              VALUE                  SOURCE
2605 pool/home/bob  type                  filesystem             -
2606 pool/home/bob  creation              Tue Jul 21 15:53 2009  -
2607 pool/home/bob  used                  21K                    -
2608 pool/home/bob  available             20.0G                  -
2609 pool/home/bob  referenced            21K                    -
2610 pool/home/bob  compressratio         1.00x                  -
2611 pool/home/bob  mounted               yes                    -
2612 pool/home/bob  quota                 20G                    local
2613 pool/home/bob  reservation           none                   default
2614 pool/home/bob  recordsize            128K                   default
2615 pool/home/bob  mountpoint            /pool/home/bob         default
2616 pool/home/bob  sharenfs              off                    default
2617 pool/home/bob  checksum              on                     default
2618 pool/home/bob  compression           on                     local
2619 pool/home/bob  atime                 on                     default
2620 pool/home/bob  devices               on                     default
2621 pool/home/bob  exec                  on                     default
2622 pool/home/bob  setuid                on                     default
2623 pool/home/bob  readonly              off                    default
2624 pool/home/bob  zoned                 off                    default
2625 pool/home/bob  snapdir               hidden                 default
2626 pool/home/bob  aclmode               groupmask              default
2627 pool/home/bob  aclinherit            restricted             default
2628 pool/home/bob  canmount              on                     default
2629 pool/home/bob  shareiscsi            off                    default
2630 pool/home/bob  xattr                 on                     default
2631 pool/home/bob  copies                1                      default
2632 pool/home/bob  version               4                      -
2633 pool/home/bob  utf8only              off                    -
2634 pool/home/bob  normalization         none                   -
2635 pool/home/bob  casesensitivity       sensitive              -
2636 pool/home/bob  vscan                 off                    default
2637 pool/home/bob  nbmand                off                    default
2638 pool/home/bob  sharesmb              off                    default
2639 pool/home/bob  refquota              none                   default
2640 pool/home/bob  refreservation        none                   default
2641 pool/home/bob  primarycache          all                    default
2642 pool/home/bob  secondarycache        all                    default
2643 pool/home/bob  usedbysnapshots       0                      -
2644 pool/home/bob  usedbydataset         21K                    -
2645 pool/home/bob  usedbychildren        0                      -
2646 pool/home/bob  usedbyrefreservation  0                      -
2647 .fi
2648 .in -2
2649 .sp
2650
2651 .sp
2652 .LP
2653 The following command gets a single property value.
2654
2655 .sp
2656 .in +2
2657 .nf
2658 # \fBzfs get -H -o value compression pool/home/bob\fR
2659 on
2660 .fi
2661 .in -2
2662 .sp
2663
2664 .sp
2665 .LP
2666 The following command lists all properties with local settings for \fBpool/home/bob\fR.
2667
2668 .sp
2669 .in +2
2670 .nf
2671 # \fBzfs get -r -s local -o name,property,value all pool/home/bob\fR
2672 NAME           PROPERTY              VALUE
2673 pool/home/bob  quota                 20G
2674 pool/home/bob  compression           on
2675 .fi
2676 .in -2
2677 .sp
2678
2679 .LP
2680 \fBExample 8 \fRRolling Back a ZFS File System
2681 .sp
2682 .LP
2683 The following command reverts the contents of \fBpool/home/anne\fR to the snapshot named \fByesterday\fR, deleting all intermediate snapshots.
2684
2685 .sp
2686 .in +2
2687 .nf
2688 # \fBzfs rollback -r pool/home/anne@yesterday\fR
2689 .fi
2690 .in -2
2691 .sp
2692
2693 .LP
2694 \fBExample 9 \fRCreating a ZFS Clone
2695 .sp
2696 .LP
2697 The following command creates a writable file system whose initial contents are the same as \fBpool/home/bob@yesterday\fR.
2698
2699 .sp
2700 .in +2
2701 .nf
2702 # \fBzfs clone pool/home/bob@yesterday pool/clone\fR
2703 .fi
2704 .in -2
2705 .sp
2706
2707 .LP
2708 \fBExample 10 \fRPromoting a ZFS Clone
2709 .sp
2710 .LP
2711 The following commands illustrate how to test out changes to a file system, and then replace the original file system with the changed one, using clones, clone promotion, and renaming:
2712
2713 .sp
2714 .in +2
2715 .nf
2716 # \fBzfs create pool/project/production\fR
2717   populate /pool/project/production with data
2718 # \fBzfs snapshot pool/project/production@today\fR
2719 # \fBzfs clone pool/project/production@today pool/project/beta\fR
2720 make changes to /pool/project/beta and test them
2721 # \fBzfs promote pool/project/beta\fR
2722 # \fBzfs rename pool/project/production pool/project/legacy\fR
2723 # \fBzfs rename pool/project/beta pool/project/production\fR
2724 once the legacy version is no longer needed, it can be destroyed
2725 # \fBzfs destroy pool/project/legacy\fR
2726 .fi
2727 .in -2
2728 .sp
2729
2730 .LP
2731 \fBExample 11 \fRInheriting ZFS Properties
2732 .sp
2733 .LP
2734 The following command causes \fBpool/home/bob\fR and \fBpool/home/anne\fR to inherit the \fBchecksum\fR property from their parent.
2735
2736 .sp
2737 .in +2
2738 .nf
2739 # \fBzfs inherit checksum pool/home/bob pool/home/anne\fR
2740 .fi
2741 .in -2
2742 .sp
2743
2744 .LP
2745 \fBExample 12 \fRRemotely Replicating ZFS Data
2746 .sp
2747 .LP
2748 The following commands send a full stream and then an incremental stream to a remote machine, restoring them into \fBpoolB/received/fs@a\fRand \fBpoolB/received/fs@b\fR, respectively. \fBpoolB\fR must contain the file system \fBpoolB/received\fR, and must not initially contain \fBpoolB/received/fs\fR.
2749
2750 .sp
2751 .in +2
2752 .nf
2753 # \fBzfs send pool/fs@a | \e\fR
2754    \fBssh host zfs receive poolB/received/fs@a\fR
2755 # \fBzfs send -i a pool/fs@b | ssh host \e\fR
2756    \fBzfs receive poolB/received/fs\fR
2757 .fi
2758 .in -2
2759 .sp
2760
2761 .LP
2762 \fBExample 13 \fRUsing the \fBzfs receive\fR \fB-d\fR Option
2763 .sp
2764 .LP
2765 The following command sends a full stream of \fBpoolA/fsA/fsB@snap\fR to a remote machine, receiving it into \fBpoolB/received/fsA/fsB@snap\fR. The \fBfsA/fsB@snap\fR portion of the received snapshot's name is determined from the name of the sent snapshot. \fBpoolB\fR must contain the file system \fBpoolB/received\fR. If \fBpoolB/received/fsA\fR does not exist, it is created as an empty file system.
2766
2767 .sp
2768 .in +2
2769 .nf
2770 # \fBzfs send poolA/fsA/fsB@snap | \e
2771    ssh host zfs receive -d poolB/received\fR
2772 .fi
2773 .in -2
2774 .sp
2775
2776 .LP
2777 \fBExample 14 \fRSetting User Properties
2778 .sp
2779 .LP
2780 The following example sets the user-defined \fBcom.example:department\fR property for a dataset.
2781
2782 .sp
2783 .in +2
2784 .nf
2785 # \fBzfs set com.example:department=12345 tank/accounting\fR
2786 .fi
2787 .in -2
2788 .sp
2789
2790 .LP
2791 \fBExample 15 \fRCreating a ZFS Volume as an iSCSI Target Device
2792 .sp
2793 .LP
2794 The following example shows how to create a \fBZFS\fR volume as an \fBiSCSI\fR target. 
2795
2796 .sp
2797 .in +2
2798 .nf
2799 # \fBzfs create -V 2g pool/volumes/vol1\fR
2800 # \fBzfs set shareiscsi=on pool/volumes/vol1\fR
2801 # \fBiscsitadm list target\fR
2802 Target: pool/volumes/vol1
2803  iSCSI Name: 
2804  iqn.1986-03.com.sun:02:7b4b02a6-3277-eb1b-e686-a24762c52a8c
2805  Connections: 0
2806 .fi
2807 .in -2
2808 .sp
2809
2810 .sp
2811 .LP
2812 After the \fBiSCSI\fR target is created, set up the \fBiSCSI\fR initiator. For more information about the Solaris \fBiSCSI\fR initiator, see \fBiscsitadm\fR(1M).
2813 .LP
2814 \fBExample 16 \fRPerforming a Rolling Snapshot
2815 .sp
2816 .LP
2817 The following example shows how to maintain a history of snapshots with a consistent naming scheme. To keep a week's worth of snapshots, the user destroys the oldest snapshot, renames the remaining snapshots, and then creates a new snapshot, as follows:
2818
2819 .sp
2820 .in +2
2821 .nf
2822 # \fBzfs destroy -r pool/users@7daysago\fR
2823 # \fBzfs rename -r pool/users@6daysago @7daysago\fR
2824 # \fBzfs rename -r pool/users@5daysago @6daysago\fR
2825 # \fBzfs rename -r pool/users@yesterday @5daysago\fR
2826 # \fBzfs rename -r pool/users@yesterday @4daysago\fR
2827 # \fBzfs rename -r pool/users@yesterday @3daysago\fR
2828 # \fBzfs rename -r pool/users@yesterday @2daysago\fR
2829 # \fBzfs rename -r pool/users@today @yesterday\fR
2830 # \fBzfs snapshot -r pool/users@today\fR
2831 .fi
2832 .in -2
2833 .sp
2834
2835 .LP
2836 \fBExample 17 \fRSetting \fBsharenfs\fR Property Options on a ZFS File System
2837 .sp
2838 .LP
2839 The following commands show how to set \fBsharenfs\fR property options to enable \fBrw\fR access for a set of \fBIP\fR addresses and to enable root access for system \fBneo\fR on the \fBtank/home\fR file system.
2840
2841 .sp
2842 .in +2
2843 .nf
2844 # \fB# zfs set sharenfs='rw=@123.123.0.0/16,root=neo' tank/home\fR
2845 .fi
2846 .in -2
2847 .sp
2848
2849 .sp
2850 .LP
2851 If you are using \fBDNS\fR for host name resolution, specify the fully qualified hostname.
2852
2853 .LP
2854 \fBExample 18 \fRDelegating ZFS Administration Permissions on a ZFS Dataset
2855 .sp
2856 .LP
2857 The following example shows how to set permissions so that user \fBcindys\fR can create, destroy, mount, and take snapshots on \fBtank/cindys\fR. The permissions on \fBtank/cindys\fR are also displayed.
2858
2859 .sp
2860 .in +2
2861 .nf
2862 # \fBzfs allow cindys create,destroy,mount,snapshot tank/cindys\fR
2863 # \fBzfs allow tank/cindys\fR
2864 -------------------------------------------------------------
2865 Local+Descendent permissions on (tank/cindys)
2866           user cindys create,destroy,mount,snapshot
2867 -------------------------------------------------------------
2868 .fi
2869 .in -2
2870 .sp
2871
2872 .sp
2873 .LP
2874 Because the \fBtank/cindys\fR mount point permission is set to 755 by default, user \fBcindys\fR will be unable to mount file systems under \fBtank/cindys\fR. Set an \fBACL\fR similar to the following syntax to provide mount point access:
2875 .sp
2876 .in +2
2877 .nf
2878 # \fBchmod A+user:cindys:add_subdirectory:allow /tank/cindys\fR
2879 .fi
2880 .in -2
2881 .sp
2882
2883 .LP
2884 \fBExample 19 \fRDelegating Create Time Permissions on a ZFS Dataset
2885 .sp
2886 .LP
2887 The following example shows how to grant anyone in the group \fBstaff\fR to create file systems in \fBtank/users\fR. This syntax also allows staff members to destroy their own file systems, but not destroy anyone else's file system. The permissions on \fBtank/users\fR are also displayed.
2888
2889 .sp
2890 .in +2
2891 .nf
2892 # \fB# zfs allow staff create,mount tank/users\fR
2893 # \fBzfs allow -c destroy tank/users\fR
2894 # \fBzfs allow tank/users\fR
2895 -------------------------------------------------------------
2896 Create time permissions on (tank/users)
2897           create,destroy
2898 Local+Descendent permissions on (tank/users)
2899           group staff create,mount
2900 ------------------------------------------------------------- 
2901 .fi
2902 .in -2
2903 .sp
2904
2905 .LP
2906 \fBExample 20 \fRDefining and Granting a Permission Set on a ZFS Dataset
2907 .sp
2908 .LP
2909 The following example shows how to define and grant a permission set on the \fBtank/users\fR file system. The permissions on \fBtank/users\fR are also displayed.
2910
2911 .sp
2912 .in +2
2913 .nf
2914 # \fBzfs allow -s @pset create,destroy,snapshot,mount tank/users\fR
2915 # \fBzfs allow staff @pset tank/users\fR
2916 # \fBzfs allow tank/users\fR
2917 -------------------------------------------------------------
2918 Permission sets on (tank/users)
2919         @pset create,destroy,mount,snapshot
2920 Create time permissions on (tank/users)
2921         create,destroy
2922 Local+Descendent permissions on (tank/users)
2923         group staff @pset,create,mount
2924 -------------------------------------------------------------
2925 .fi
2926 .in -2
2927 .sp
2928
2929 .LP
2930 \fBExample 21 \fRDelegating Property Permissions on a ZFS Dataset
2931 .sp
2932 .LP
2933 The following example shows to grant the ability to set quotas and reservations on the \fBusers/home\fR file system. The permissions on \fBusers/home\fR are also displayed.
2934
2935 .sp
2936 .in +2
2937 .nf
2938 # \fBzfs allow cindys quota,reservation users/home\fR
2939 # \fBzfs allow users/home\fR
2940 -------------------------------------------------------------
2941 Local+Descendent permissions on (users/home)
2942         user cindys quota,reservation
2943 -------------------------------------------------------------
2944 cindys% \fBzfs set quota=10G users/home/marks\fR
2945 cindys% \fBzfs get quota users/home/marks\fR
2946 NAME              PROPERTY  VALUE             SOURCE
2947 users/home/marks  quota     10G               local 
2948 .fi
2949 .in -2
2950 .sp
2951
2952 .LP
2953 \fBExample 22 \fRRemoving ZFS Delegated Permissions on a ZFS Dataset
2954 .sp
2955 .LP
2956 The following example shows how to remove the snapshot permission from the \fBstaff\fR group on the \fBtank/users\fR file system. The permissions on \fBtank/users\fR are also displayed.
2957
2958 .sp
2959 .in +2
2960 .nf
2961 # \fBzfs unallow staff snapshot tank/users\fR
2962 # \fBzfs allow tank/users\fR
2963 -------------------------------------------------------------
2964 Permission sets on (tank/users)
2965         @pset create,destroy,mount,snapshot
2966 Create time permissions on (tank/users)
2967         create,destroy
2968 Local+Descendent permissions on (tank/users)
2969         group staff @pset,create,mount
2970 ------------------------------------------------------------- 
2971 .fi
2972 .in -2
2973 .sp
2974
2975 .SH EXIT STATUS
2976 .sp
2977 .LP
2978 The following exit values are returned:
2979 .sp
2980 .ne 2
2981 .mk
2982 .na
2983 \fB\fB0\fR\fR
2984 .ad
2985 .sp .6
2986 .RS 4n
2987 Successful completion. 
2988 .RE
2989
2990 .sp
2991 .ne 2
2992 .mk
2993 .na
2994 \fB\fB1\fR\fR
2995 .ad
2996 .sp .6
2997 .RS 4n
2998 An error occurred.
2999 .RE
3000
3001 .sp
3002 .ne 2
3003 .mk
3004 .na
3005 \fB\fB2\fR\fR
3006 .ad
3007 .sp .6
3008 .RS 4n
3009 Invalid command line options were specified.
3010 .RE
3011
3012 .SH SEE ALSO
3013 .sp
3014 .LP
3015 \fBchmod\fR(2), \fBfsync\fR(2), \fBgzip\fR(1), \fBmount\fR(8), \fBssh\fR(1), \fBstat\fR(2), \fBwrite\fR(2), \fBzpool\fR(8)