2 .\" Copyright (c) 2013, Martin Matuska <mm@FreeBSD.org>.
3 .\" All Rights Reserved.
5 .\" The contents of this file are subject to the terms of the
6 .\" Common Development and Distribution License (the "License").
7 .\" You may not use this file except in compliance with the License.
9 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 .\" or http://www.opensolaris.org/os/licensing.
11 .\" See the License for the specific language governing permissions
12 .\" and limitations under the License.
14 .\" When distributing Covered Code, include this CDDL HEADER in each
15 .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 .\" If applicable, add the following below this CDDL HEADER, with the
17 .\" fields enclosed by brackets "[]" replaced with your own identifying
18 .\" information: Portions Copyright [yyyy] [name of copyright owner]
20 .\" Copyright (c) 2010, Sun Microsystems, Inc. All Rights Reserved.
21 .\" Copyright (c) 2011, 2014 by Delphix. All rights reserved.
22 .\" Copyright (c) 2011, Pawel Jakub Dawidek <pjd@FreeBSD.org>
23 .\" Copyright (c) 2012, Glen Barber <gjb@FreeBSD.org>
24 .\" Copyright (c) 2012, Bryan Drewery <bdrewery@FreeBSD.org>
25 .\" Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
26 .\" Copyright (c) 2014, Joyent, Inc. All rights reserved.
27 .\" Copyright (c) 2013, Steven Hartland <smh@FreeBSD.org>
28 .\" Copyright (c) 2016 Nexenta Systems, Inc. All Rights Reserved.
29 .\" Copyright (c) 2014, Xin LI <delphij@FreeBSD.org>
30 .\" Copyright (c) 2014-2015, The FreeBSD Foundation, All Rights Reserved.
31 .\" Copyright 2018 Joyent, Inc.
32 .\" Copyright (c) 2018 Datto Inc.
41 .Nd configures ZFS file systems
48 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ... Ar filesystem
53 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
59 .Ar filesystem Ns | Ns Ar volume
64 .Ar filesystem Ns | Ns volume
67 .Op , Ns Ar snap Op % Ns Ar snap
72 .Ar filesystem Ns | Ns Ar volume Ns # Ns Ar bookmark
74 .Cm snapshot Ns | Ns Cm snap
76 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
77 .Ar filesystem@snapname Ns | Ns Ar volume@snapname
78 .Ar filesystem@snapname Ns | Ns Ar volume@snapname Ns ...
86 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
87 .Ar snapshot filesystem Ns | Ns Ar volume
94 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
95 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
100 .Ar filesystem Ns | Ns Ar volume
101 .Ar filesystem Ns | Ns Ar volume
105 .Ar snapshot snapshot
108 .Ar bookmark bookmark
113 .Ar filesystem filesystem
116 .Op Fl r Ns | Ns Fl d Ar depth
118 .Op Fl o Ar property Ns Oo , Ns property Ns Oc Ns ...
119 .Op Fl t Ar type Ns Oo , Ns type Ns Oc Ns ...
120 .Oo Fl s Ar property Oc Ns ...
121 .Oo Fl S Ar property Oc Ns ...
122 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot | Ns Ar bookmark Ns ...
125 .Ar filesystem Ns | Ns Ar volume
128 .Ar property Ns = Ns Ar value Oo Ar property Ns = Ns Ar value Oc Ns ...
129 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns ...
132 .Op Fl r Ns | Ns Fl d Ar depth
134 .Op Fl o Ar all | field Ns Oo , Ns Ar field Oc Ns ...
135 .Op Fl t Ar type Ns Oo Ns , Ar type Oc Ns ...
136 .Op Fl s Ar source Ns Oo Ns , Ns Ar source Oc Ns ...
137 .Ar all | property Ns Oo Ns , Ns Ar property Oc Ns ...
138 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns ...
143 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns ...
151 .Fl a | Ar filesystem
155 .Op Fl o Ar field Ns Oo , Ns Ar field Oc Ns ...
156 .Oo Fl s Ar field Oc Ns ...
157 .Oo Fl S Ar field Oc Ns ...
158 .Op Fl t Ar type Ns Oo Ns , Ns Ar type Oc Ns ...
159 .Ar filesystem Ns | Ns Ar snapshot
163 .Op Fl o Ar field Ns Oo , Ns field Oc Ns ...
164 .Oo Fl s Ar field Oc Ns ...
165 .Oo Fl S Ar field Oc Ns ...
166 .Op Fl t Ar type Ns Oo Ns , Ns Ar type Oc Ns ...
167 .Ar filesystem Ns | Ns Ar snapshot
173 .Op Fl o Ar property Ns Oo , Ns Ar property Oc Ns ...
174 .Fl a | Ar filesystem
176 .Cm unmount Ns | Ns Cm umount
178 .Fl a | Ar filesystem Ns | Ns Ar mountpoint
181 .Fl a | Ar filesystem
184 .Fl a | Ar filesystem Ns | Ns Ar mountpoint
192 .Op Fl i Ar snapshot | Fl I Ar snapshot
197 .Op Fl i Ar snapshot Ns | Ns Ar bookmark
198 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
202 .Fl t Ar receive_resume_token
204 .Cm receive Ns | Ns Cm recv
206 .Op Fl o Sy origin Ns = Ns Ar snapshot
207 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
209 .Cm receive Ns | Ns Cm recv
212 .Op Fl o Sy origin Ns = Ns Ar snapshot
215 .Cm receive Ns | Ns Cm recv
217 .Ar filesystem Ns | Ns Ar volume
220 .Ar filesystem Ns | Ns Ar volume
224 .Ar user Ns | Ns Ar group Ns Oo Ns , Ns Ar user Ns | Ns Ar group Oc Ns ...
225 .Ar perm Ns | Ns Ar @setname Ns
226 .Oo Ns , Ns Ar perm Ns | Ns Ar @setname Oc Ns ...
227 .Ar filesystem Ns | Ns Ar volume
231 .Fl e Ns | Ns Cm everyone
232 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
234 .Ar filesystem Ns | Ns Ar volume
238 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
240 .Ar filesystem Ns | Ns Ar volume
245 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
247 .Ar filesystem Ns | Ns Ar volume
251 .Ar user Ns | Ns Ar group Ns Oo Ns , Ns Ar user Ns | Ns Ar group Oc Ns ...
252 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
254 .Ar filesystem Ns | Ns Ar volume
258 .Fl e Ns | Ns Cm everyone
259 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
261 .Ar filesystem Ns | Ns Ar volume
266 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
268 .Ar filesystem Ns | Ns Ar volume
274 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
276 .Ar filesystem Ns | Ns Ar volume
280 .Ar tag snapshot Ns ...
284 .Op Fl r Ns | Ns Fl d Ar depth
285 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns
290 .Ar tag snapshot Ns ...
295 .Op Ar snapshot Ns | Ns Ar filesystem
300 .Op Fl m Ar memory_limit
305 .Ar jailid Ns | Ns Ar jailname filesystem
308 .Ar jailid Ns | Ns Ar jailname filesystem
316 storage pool, as described in
318 A dataset is identified by a unique path within the
320 namespace. For example:
321 .Bd -ragged -offset 4n
322 .No pool/ Ns Brq filesystem,volume,snapshot
325 where the maximum length of a dataset name is
328 and the maximum amount of nesting allowed in a path is 50 levels deep.
330 A dataset can be one of the following:
337 can be mounted within the standard system namespace and behaves like other file
340 file systems are designed to be
342 compliant, known issues exist that prevent compliance in some cases.
343 Applications that depend on standards conformance might fail due to nonstandard
344 behavior when checking file system free space.
346 A logical volume exported as a raw or block device. This type of dataset should
347 only be used under special circumstances. File systems are typically used in
350 A read-only version of a file system or volume at a given point in time. It is
356 .Ss ZFS File System Hierarchy
359 storage pool is a logical collection of devices that provide space for
360 datasets. A storage pool is also the root of the
362 file system hierarchy.
364 The root of the pool can be accessed as a file system, such as mounting and
365 unmounting, taking snapshots, and setting properties. The physical storage
366 characteristics, however, are managed by the
372 for more information on creating and administering pools.
374 A snapshot is a read-only copy of a file system or volume. Snapshots can be
375 created extremely quickly, and initially consume no additional space within the
376 pool. As data within the active dataset changes, the snapshot consumes more
377 data than would otherwise be shared with the active dataset.
379 Snapshots can have arbitrary names. Snapshots of volumes can be cloned or
380 rolled back, but cannot be accessed independently.
382 File system snapshots can be accessed under the
384 directory in the root of the file system. Snapshots are automatically mounted
385 on demand and may be unmounted at regular intervals. The visibility of the
387 directory can be controlled by the
391 A clone is a writable volume or file system whose initial contents are the same
392 as another dataset. As with snapshots, creating a clone is nearly
393 instantaneous, and initially consumes no additional space.
395 Clones can only be created from a snapshot. When a snapshot is cloned, it
396 creates an implicit dependency between the parent and child. Even though the
397 clone is created somewhere else in the dataset hierarchy, the original snapshot
398 cannot be destroyed as long as a clone exists. The
400 property exposes this dependency, and the
402 command lists any such dependencies, if they exist.
404 The clone parent-child dependency relationship can be reversed by using the
406 subcommand. This causes the "origin" file system to become a clone of the
407 specified file system, which makes it possible to destroy the file system that
408 the clone was created from.
412 file system is a simple operation, so the number of file systems per system is
413 likely to be numerous. To cope with this,
415 automatically manages mounting and unmounting file systems without the need to
418 file. All automatically managed file systems are mounted by
422 By default, file systems are mounted under
426 is the name of the file system in the
428 namespace. Directories are created and destroyed as needed.
430 A file system can also have a mount point set in the
432 property. This directory is created as needed, and
434 automatically mounts the file system when the
436 command is invoked (without editing
440 property can be inherited, so if
446 automatically inherits a mount point of
453 prevents the file system from being mounted.
457 file systems can also be managed with traditional tools
458 .Pq Xr mount 8 , Xr umount 8 , Xr fstab 5 .
459 If a file system's mount point is set to
462 makes no attempt to manage the file system, and the administrator is
463 responsible for mounting and unmounting the file system.
466 dataset can be attached to a jail by using the
468 subcommand. You cannot attach a dataset to one jail and the children of the
469 same dataset to another jail. You can also not attach the root file system
470 of the jail or any dataset which needs to be mounted before the zfs rc script
471 is run inside the jail, as it would be attached unmounted until it is
472 mounted from the rc script inside the jail. To allow management of the
473 dataset from within a jail, the
475 property has to be set and the jail needs access to the
479 property cannot be changed from within a jail. See
481 for information on how to allow mounting
483 datasets from within a jail.
486 dataset can be detached from a jail using the
490 After a dataset is attached to a jail and the jailed property is set, a jailed
491 file system cannot be mounted outside the jail, since the jail administrator
492 might have set the mount point to an unacceptable value.
494 Deduplication is the process for removing redundant data at the block-level,
495 reducing the total amount of data stored. If a file system has the
497 property enabled, duplicate data blocks are removed synchronously. The result
498 is that only unique data is stored and common components are shared among
500 .Ss Native Properties
501 Properties are divided into two types, native properties and user-defined (or
502 "user") properties. Native properties either export internal statistics or
505 behavior. In addition, native properties are either editable or read-only. User
506 properties have no effect on
508 behavior, but you can use them to annotate datasets in a way that is meaningful
509 in your environment. For more information about user properties, see the
510 .Qq Sx User Properties
513 Every dataset has a set of properties that export statistics about the dataset
514 as well as control various behaviors. Properties are inherited from the parent
515 unless overridden by the child. Some properties apply only to certain types of
516 datasets (file systems, volumes, or snapshots).
518 The values of numeric properties can be specified using human-readable suffixes
520 .Sy k , KB , M , Gb ,
523 for zettabyte). The following are all valid (and equal) specifications:
524 .Bd -ragged -offset 4n
528 The values of non-numeric properties are case sensitive and must be lowercase,
530 .Sy mountpoint , sharenfs , No and Sy sharesmb .
532 The following native properties consist of read-only statistics about the
533 dataset. These properties can be neither set, nor inherited. Native properties
534 apply to all dataset types unless otherwise noted.
537 The amount of space available to the dataset and all its children, assuming
538 that there is no other activity in the pool. Because space is shared within a
539 pool, availability can be limited by any number of factors, including physical
540 pool size, quotas, reservations, or other datasets within the pool.
542 This property can also be referred to by its shortened column name,
545 For non-snapshots, the compression ratio achieved for the
547 space of this dataset, expressed as a multiplier. The
549 property includes descendant datasets, and, for clones, does not include
550 the space shared with the origin snapshot. For snapshots, the
554 property. Compression can be turned on by running:
555 .Qq Nm Cm set compression=on Ar dataset
559 The transaction group (txg) in which the dataset was created.
560 Bookmarks have the same
562 as the snapshot they are initially tied to.
563 This property is suitable for ordering a list of snapshots,
564 e.g. for incremental send and receive.
566 The time this dataset was created.
568 For snapshots, this property is a comma-separated list of filesystems or
569 volumes which are clones of this snapshot. The clones'
571 property is this snapshot. If the
573 property is not empty, then this snapshot can not be destroyed (even with the
581 if the snapshot has been marked for deferred destroy by using the
583 command. Otherwise, the property is
585 .It Sy filesystem_count
586 The total number of filesystems and volumes that exist under this location in the
588 This value is only available when a
591 been set somewhere in the tree under which the dataset resides.
593 The 64 bit GUID of this dataset or bookmark which does not change over its
595 When a snapshot is sent to another pool, the received snapshot has the same
599 is suitable to identify a snapshot across pools.
600 .It Sy logicalreferenced
601 The amount of space that is
603 accessible by this dataset.
607 The logical space ignores the effect of the
611 properties, giving a quantity closer to the amount of data that applications
613 However, it does include space consumed by metadata.
615 This property can also be referred to by its shortened column name,
618 The amount of space that is
620 consumed by this dataset and all its descendents.
624 The logical space ignores the effect of the
628 properties, giving a quantity closer to the amount of data that applications
631 This property can also be referred to by its shortened column name,
634 For file systems, indicates whether the file system is currently mounted. This
635 property can be either
640 For cloned file systems or volumes, the snapshot from which the clone was
641 created. See also the
644 .It Sy receive_resume_token
645 For filesystems or volumes which have saved partially-completed state from
647 this opaque token can be provided to
649 to resume and complete the
652 The amount of data that is accessible by this dataset, which may or may not be
653 shared with other datasets in the pool. When a snapshot or clone is created, it
654 initially references the same amount of space as the file system or snapshot it
655 was created from, since its contents are identical.
657 This property can also be referred to by its shortened column name,
659 .It Sy refcompressratio
660 The compression ratio achieved for the
662 space of this dataset, expressed as a multiplier. See also the
665 .It Sy snapshot_count
666 The total number of snapshots that exist under this location in the dataset tree.
667 This value is only available when a
669 has been set somewhere
670 in the tree under which the dataset resides.
673 .Sy filesystem , volume , No or Sy snapshot .
675 The amount of space consumed by this dataset and all its descendents. This is
676 the value that is checked against this dataset's quota and reservation. The
677 space used does not include this dataset's reservation, but does take into
678 account the reservations of any descendent datasets. The amount of space that a
679 dataset consumes from its parent, as well as the amount of space that are freed
680 if this dataset is recursively destroyed, is the greater of its space used and
683 When snapshots (see the
685 section) are created, their space is
686 initially shared between the snapshot and the file system, and possibly with
687 previous snapshots. As the file system changes, space that was previously
688 shared becomes unique to the snapshot, and counted in the snapshot's space
689 used. Additionally, deleting snapshots can increase the amount of space unique
690 to (and used by) other snapshots.
692 The amount of space used, available, or referenced does not take into account
693 pending changes. Pending changes are generally accounted for within a few
694 seconds. Committing a change to a disk using
698 does not necessarily guarantee that the space usage information is updated
703 properties decompose the
705 properties into the various reasons that space is used. Specifically,
707 .Sy usedbysnapshots + usedbydataset + usedbychildren + usedbyrefreservation .
708 These properties are only available for datasets created
711 pool version 13 pools and higher.
712 .It Sy usedbysnapshots
713 The amount of space consumed by snapshots of this dataset. In particular, it is
714 the amount of space that would be freed if all of this dataset's snapshots were
715 destroyed. Note that this is not simply the sum of the snapshots'
717 properties because space can be shared by multiple snapshots.
719 The amount of space used by this dataset itself, which would be freed if the
720 dataset were destroyed (after first removing any
722 and destroying any necessary snapshots or descendents).
723 .It Sy usedbychildren
724 The amount of space used by children of this dataset, which would be freed if
725 all the dataset's children were destroyed.
726 .It Sy usedbyrefreservation
727 The amount of space used by a
729 set on this dataset, which would be freed if the
732 .It Sy userused@ Ns Ar user
733 The amount of space consumed by the specified user in this dataset. Space is
734 charged to the owner of each file, as displayed by
736 The amount of space charged is displayed by
742 subcommand for more information.
744 Unprivileged users can access only their own space usage. The root user, or a
745 user who has been granted the
749 can access everyone's usage.
753 properties are not displayed by
755 The user's name must be appended after the
757 symbol, using one of the following forms:
758 .Bl -bullet -offset 2n
760 POSIX name (for example,
763 POSIX numeric ID (for example,
767 This property is set to the number of user holds on this snapshot. User holds
771 .It Sy groupused@ Ns Ar group
772 The amount of space consumed by the specified group in this dataset. Space is
773 charged to the group of each file, as displayed by
776 .Sy userused@ Ns Ar user
777 property for more information.
779 Unprivileged users can only access their own groups' space usage. The root
780 user, or a user who has been granted the
784 can access all groups' usage.
785 .It Sy volblocksize Ns = Ns Ar blocksize
786 For volumes, specifies the block size of the volume. The
788 cannot be changed once the volume has been written, so it should be set at
789 volume creation time. The default
791 for volumes is 8 Kbytes. Any
792 power of 2 from 512 bytes to 128 Kbytes is valid.
794 This property can also be referred to by its shortened column name,
799 space written to this dataset since the previous snapshot.
800 .It Sy written@ Ns Ar snapshot
803 space written to this dataset since the specified snapshot. This is the space
804 that is referenced by this dataset but was not referenced by the specified
809 may be specified as a short snapshot name (just the part after the
811 in which case it will be interpreted as a snapshot in the same filesystem as
814 may be a full snapshot name
815 .Pq Em filesystem@snapshot ,
816 which for clones may be a snapshot in the origin's filesystem (or the origin of
817 the origin's filesystem, etc).
820 The following native properties can be used to change the behavior of a
825 .Sy aclinherit Ns = Ns Cm discard |
833 entries are inherited when files and directories are created. A file system
840 entries. A file system with an
844 only inherits inheritable
846 entries that specify "deny" permissions. The property value
848 (the default) removes the
854 entry is inherited. A file system with an
858 inherits all inheritable
860 entries without any modifications made to the
862 entries when they are inherited. A file system with an
866 has the same meaning as
869 .Em owner@ , group@ , No and Em everyone@ Tn ACE Ns s
870 inherit the execute permission only if the file creation mode also requests the
873 When the property value is set to
875 files are created with a mode determined by the inheritable
879 exist that affect the mode, then the mode is set in accordance to the requested
880 mode from the application.
881 .It Sy aclmode Ns = Ns Cm discard | groupmask | passthrough | restricted
886 A file system with an
890 (the default) deletes all
892 entries that do not represent the mode of the file. An
896 reduces permissions granted in all
900 such that they are no greater than the group permissions specified by
902 A file system with an
906 indicates that no changes are made to the
908 other than creating or updating the necessary
910 entries to represent the new mode of the file or directory.
917 operation to return an error when used on any file or directory which has
920 whose entries can not be represented by a mode.
922 is required to change the set user ID, set group ID, or sticky bits on a file
923 or directory, as they do not have equivalent
928 on a file or directory with a non-trivial
934 you must first remove all
936 entries which do not represent the current mode.
937 .It Sy atime Ns = Ns Cm on | off
938 Controls whether the access time for files is updated when they are read.
939 Turning this property off avoids producing write traffic when reading files and
940 can result in significant performance gains, though it might confuse mailers
941 and other similar utilities. The default value is
943 .It Sy canmount Ns = Ns Cm on | off | noauto
944 If this property is set to
946 the file system cannot be mounted, and is ignored by
947 .Qq Nm Cm mount Fl a .
948 Setting this property to
950 is similar to setting the
954 except that the dataset still has a normal
956 property, which can be inherited. Setting this property to
958 allows datasets to be used solely as a mechanism to inherit properties. One
960 .Sy canmount Ns = Ns Cm off
961 is to have two datasets with the same
963 so that the children of both datasets appear in the same directory, but might
964 have different inherited characteristics.
968 value is set, a dataset can only be mounted and unmounted explicitly. The
969 dataset is not mounted automatically when the dataset is created or imported,
970 nor is it mounted by the
972 command or unmounted by the
973 .Qq Nm Cm umount Fl a
976 This property is not inherited.
977 .It Sy checksum Ns = Ns Cm on | off | fletcher2 | fletcher4 | sha256 | noparity | sha512 | skein
978 Controls the checksum used to verify data integrity. The default value is
980 which automatically selects an appropriate algorithm (currently,
982 but this may change in future releases). The value
984 disables integrity checking on user data.
988 disables integrity but also disables maintaining parity for user data. This
989 setting is used internally by a dump device residing on a RAID-Z pool and should
990 not be used by any other dataset.
991 Disabling checksums is
993 a recommended practice.
998 checksum algorithms require enabling the appropriate features on the pool.
1000 .Xr zpool-features 7
1001 for more information on these algorithms.
1003 Changing this property affects only newly-written data.
1005 Salted checksum algorithms
1006 .Pq Cm edonr , skein
1007 are currently not supported for any filesystem on the boot pools.
1008 .It Sy compression Ns = Ns Cm on | off | lzjb | gzip | gzip- Ns Ar N | Cm zle | Cm lz4
1009 Controls the compression algorithm used for this dataset.
1010 Setting compression to
1012 indicates that the current default compression algorithm should be used.
1013 The default balances compression and decompression speed, with compression
1014 ratio and is expected to work well on a wide variety of workloads.
1015 Unlike all other settings for this property, on does not select a fixed
1017 As new compression algorithms are added to ZFS and enabled on a pool, the
1018 default compression algorithm may change.
1019 The current default compression algorthm is either
1027 compression algorithm is optimized for performance while providing decent data
1028 compression. Setting compression to
1032 compression algorithm. The
1034 compression algorithm uses the same compression as the
1036 command. You can specify the
1038 level by using the value
1042 is an integer from 1 (fastest) to 9 (best compression ratio). Currently,
1046 (which is also the default for
1050 compression algorithm compresses runs of zeros.
1054 compression algorithm is a high-performance replacement
1057 algorithm. It features significantly faster
1058 compression and decompression, as well as a moderately higher
1059 compression ratio than
1061 but can only be used on pools with
1067 .Xr zpool-features 7
1068 for details on ZFS feature flags and the
1072 This property can also be referred to by its shortened column name
1074 Changing this property affects only newly-written data.
1075 .It Sy copies Ns = Ns Cm 1 | 2 | 3
1076 Controls the number of copies of data stored for this dataset. These copies are
1077 in addition to any redundancy provided by the pool, for example, mirroring or
1078 RAID-Z. The copies are stored on different disks, if possible. The space used
1079 by multiple copies is charged to the associated file and dataset, changing the
1081 property and counting against quotas and reservations.
1083 Changing this property only affects newly-written data. Therefore, set this
1084 property at file system creation time by using the
1085 .Fl o Cm copies= Ns Ar N
1087 .It Sy dedup Ns = Ns Cm on | off | verify | sha256 Ns Oo Cm ,verify Oc | Sy sha512 Ns Oo Cm ,verify Oc | Sy skein Ns Oo Cm ,verify Oc
1088 Configures deduplication for a dataset. The default value is
1090 The default deduplication checksum is
1092 (this may change in the future).
1095 is enabled, the checksum defined here overrides the
1097 property. Setting the value to
1099 has the same effect as the setting
1105 will do a byte-to-byte comparsion in case of two blocks having the same
1106 signature to make sure the block contents are identical.
1107 .It Sy devices Ns = Ns Cm on | off
1110 property is currently not supported on
1112 .It Sy exec Ns = Ns Cm on | off
1113 Controls whether processes can be executed from within this file system. The
1116 .It Sy mlslabel Ns = Ns Ar label | Cm none
1119 property is currently not supported on
1121 .It Sy filesystem_limit Ns = Ns Ar count | Cm none
1122 Limits the number of filesystems and volumes that can exist under this point in
1124 The limit is not enforced if the user is allowed to change
1127 .Sy filesystem_limit
1128 on a descendent of a filesystem that
1130 .Sy filesystem_limit
1131 does not override the ancestor's
1132 .Sy filesystem_limit ,
1133 but rather imposes an additional limit.
1134 This feature must be enabled to be used
1136 .Xr zpool-features 7
1138 .It Sy mountpoint Ns = Ns Ar path | Cm none | legacy
1139 Controls the mount point used for this file system. See the
1141 section for more information on how this property is used.
1145 property is changed for a file system, the file system and any children that
1146 inherit the mount point are unmounted. If the new value is
1148 then they remain unmounted. Otherwise, they are automatically remounted in the
1149 new location if the property was previously
1153 or if they were mounted before the property was changed. In addition, any
1154 shared file systems are unshared and shared in the new location.
1155 .It Sy nbmand Ns = Ns Cm on | off
1158 property is currently not supported on
1160 .It Sy primarycache Ns = Ns Cm all | none | metadata
1161 Controls what is cached in the primary cache (ARC). If this property is set to
1163 then both user data and metadata is cached. If this property is set to
1165 then neither user data nor metadata is cached. If this property is set to
1167 then only metadata is cached. The default value is
1169 .It Sy quota Ns = Ns Ar size | Cm none
1170 Limits the amount of space a dataset and its descendents can consume. This
1171 property enforces a hard limit on the amount of space used. This includes all
1172 space consumed by descendents, including file systems and snapshots. Setting a
1173 quota on a descendent of a dataset that already has a quota does not override
1174 the ancestor's quota, but rather imposes an additional limit.
1176 Quotas cannot be set on volumes, as the
1178 property acts as an implicit quota.
1179 .It Sy snapshot_limit Ns = Ns Ar count | Cm none
1180 Limits the number of snapshots that can be created on a dataset and its
1184 on a descendent of a dataset that already
1187 does not override the ancestor's
1188 .Sy snapshot_limit ,
1190 rather imposes an additional limit.
1191 The limit is not enforced if the user is
1192 allowed to change the limit.
1193 For example, this means that recursive snapshots
1194 taken from the global zone are counted against each delegated dataset within
1196 This feature must be enabled to be used
1198 .Xr zpool-features 7
1200 .It Sy userquota@ Ns Ar user Ns = Ns Ar size | Cm none
1201 Limits the amount of space consumed by the specified user.
1206 space calculation does not include space that is used by descendent datasets,
1207 such as snapshots and clones. User space consumption is identified by the
1208 .Sy userspace@ Ns Ar user
1211 Enforcement of user quotas may be delayed by several seconds. This delay means
1212 that a user might exceed their quota before the system notices that they are
1213 over quota and begins to refuse additional writes with the
1215 error message. See the
1217 subcommand for more information.
1219 Unprivileged users can only access their own groups' space usage. The root
1220 user, or a user who has been granted the
1224 can get and set everyone's quota.
1226 This property is not available on volumes, on file systems before version 4, or
1227 on pools before version 15. The
1228 .Sy userquota@ Ns ...
1229 properties are not displayed by
1231 The user's name must be appended after the
1233 symbol, using one of the following forms:
1234 .Bl -bullet -offset 2n
1236 POSIX name (for example,
1239 POSIX numeric ID (for example,
1242 .It Sy groupquota@ Ns Ar group Ns = Ns Ar size | Cm none
1243 Limits the amount of space consumed by the specified group. Group space
1244 consumption is identified by the
1245 .Sy userquota@ Ns Ar user
1248 Unprivileged users can access only their own groups' space usage. The root
1249 user, or a user who has been granted the
1253 can get and set all groups' quotas.
1254 .It Sy readonly Ns = Ns Cm on | off
1255 Controls whether this dataset can be modified. The default value is
1257 .It Sy recordsize Ns = Ns Ar size
1258 Specifies a suggested block size for files in the file system. This property is
1259 designed solely for use with database workloads that access files in fixed-size
1262 automatically tunes block sizes according to internal algorithms optimized for
1263 typical access patterns.
1265 For databases that create very large files but access them in small random
1266 chunks, these algorithms may be suboptimal. Specifying a
1268 greater than or equal to the record size of the database can result in
1269 significant performance gains. Use of this property for general purpose file
1270 systems is strongly discouraged, and may adversely affect performance.
1272 The size specified must be a power of two greater than or equal to 512 and less
1273 than or equal to 128 Kbytes.
1276 feature is enabled on the pool, the size may be up to 1 Mbyte.
1278 .Xr zpool-features 7
1279 for details on ZFS feature flags.
1281 Changing the file system's
1283 affects only files created afterward; existing files are unaffected.
1285 This property can also be referred to by its shortened column name,
1287 .It Sy redundant_metadata Ns = Ns Cm all | most
1288 Controls what types of metadata are stored redundantly.
1289 ZFS stores an extra copy of metadata, so that if a single block is corrupted,
1290 the amount of user data lost is limited.
1291 This extra copy is in addition to any redundancy provided at the pool level
1292 .Pq e.g. by mirroring or RAID-Z ,
1293 and is in addition to an extra copy specified by the
1296 .Pq up to a total of 3 copies .
1297 For example if the pool is mirrored,
1298 .Cm copies Ns = Ns Ar 2 ,
1300 .Cm redundant_metadata Ns = Ns Ar most ,
1302 stores 6 copies of most metadata, and 4 copies of data and some
1307 ZFS stores an extra copy of all metadata.
1309 single on-disk block is corrupt, at worst a single block of user data
1318 ZFS stores an extra copy of most types of
1320 This can improve performance of random writes, because less
1321 metadata must be written.
1322 In practice, at worst about 100 blocks
1327 of user data can be lost if a single
1328 on-disk block is corrupt.
1329 The exact behavior of which metadata blocks
1330 are stored redundantly may change in future releases.
1332 The default value is
1334 .It Sy refquota Ns = Ns Ar size | Cm none
1335 Limits the amount of space a dataset can consume. This property enforces a hard
1336 limit on the amount of space used. This hard limit does not include space used
1337 by descendents, including file systems and snapshots.
1338 .It Sy refreservation Ns = Ns Ar size | Cm none | Cm auto
1339 The minimum amount of space guaranteed to a dataset, not including its
1340 descendents. When the amount of space used is below this value, the dataset is
1341 treated as if it were taking up the amount of space specified by
1342 .Sy refreservation .
1345 reservation is accounted for in the parent datasets' space used, and counts
1346 against the parent datasets' quotas and reservations.
1350 is set, a snapshot is only allowed if there is enough free pool space outside
1351 of this reservation to accommodate the current number of "referenced" bytes in
1358 a volume is thick provisioned or not sparse.
1359 .Sy refreservation Ns = Cm auto
1360 is only supported on volumes.
1363 in the Native Properties
1364 section for more information about sparse volumes.
1366 This property can also be referred to by its shortened column name,
1368 .It Sy reservation Ns = Ns Ar size | Cm none
1369 The minimum amount of space guaranteed to a dataset and its descendents. When
1370 the amount of space used is below this value, the dataset is treated as if it
1371 were taking up the amount of space specified by its reservation. Reservations
1372 are accounted for in the parent datasets' space used, and count against the
1373 parent datasets' quotas and reservations.
1375 This property can also be referred to by its shortened column name,
1377 .It Sy secondarycache Ns = Ns Cm all | none | metadata
1378 Controls what is cached in the secondary cache (L2ARC). If this property is set
1381 then both user data and metadata is cached. If this property is set to
1383 then neither user data nor metadata is cached. If this property is set to
1385 then only metadata is cached. The default value is
1387 .It Sy setuid Ns = Ns Cm on | off
1388 Controls whether the
1390 bit is respected for the file system. The default value is
1392 .It Sy sharesmb Ns = Ns Cm on | off | Ar opts
1395 property currently has no effect on
1397 .It Sy sharenfs Ns = Ns Cm on | off | Ar opts
1398 Controls whether the file system is shared via
1400 and what options are used. A file system with a
1404 is managed the traditional way via
1406 Otherwise, the file system is automatically shared and unshared with the
1410 commands. If the property is set to
1414 export options are used. Otherwise,
1416 export options are equivalent to the contents of this property. The export
1417 options may be comma-separated. See
1419 for a list of valid options.
1423 property is changed for a dataset, the
1426 .It Sy logbias Ns = Ns Cm latency | throughput
1429 about handling of synchronous requests in this dataset.
1436 will use pool log devices (if configured) to handle the requests at low
1442 will not use configured pool log devices.
1444 will instead optimize synchronous operations for global pool throughput and
1445 efficient use of resources.
1446 .It Sy snapdir Ns = Ns Cm hidden | visible
1447 Controls whether the
1449 directory is hidden or visible in the root of the file system as discussed in
1452 section. The default value is
1454 .It Sy sync Ns = Ns Cm standard | always | disabled
1455 Controls the behavior of synchronous requests (e.g.
1457 O_DSYNC). This property accepts the following values:
1458 .Bl -tag -offset 4n -width 8n
1460 This is the POSIX specified behavior of ensuring all synchronous requests are
1461 written to stable storage and all devices are flushed to ensure data is not
1462 cached by device controllers (this is the default).
1464 All file system transactions are written and flushed before their system calls
1465 return. This has a large performance penalty.
1467 Disables synchronous requests. File system transactions are only committed to
1468 stable storage periodically. This option will give the highest performance.
1469 However, it is very dangerous as
1471 would be ignoring the synchronous transaction demands of applications such as
1474 Administrators should only use this option when the risks are understood.
1476 .It Sy volsize Ns = Ns Ar size
1477 For volumes, specifies the logical size of the volume. By default, creating a
1478 volume establishes a reservation of equal size. For storage pools with a
1479 version number of 9 or higher, a
1481 is set instead. Any changes to
1483 are reflected in an equivalent change to the reservation (or
1484 .Sy refreservation ) .
1487 can only be set to a multiple of
1491 The reservation is kept equal to the volume's logical size to prevent
1492 unexpected behavior for consumers. Without the reservation, the volume could
1493 run out of space, resulting in undefined behavior or data corruption, depending
1494 on how the volume is used. These effects can also occur when the volume size is
1495 changed while it is in use (particularly when shrinking the size). Extreme care
1496 should be used when adjusting the volume size.
1498 Though not recommended, a "sparse volume" (also known as "thin provisioned")
1499 can be created by specifying the
1502 .Qq Nm Cm create Fl V
1503 command, or by changing the value of the
1509 version 8 or earlier
1511 after the volume has been created.
1512 A "sparse volume" is a volume where the value of
1514 is less then the size of the volume plus the space required to store its
1516 Consequently, writes to a sparse volume can fail with
1518 when the pool is low on space. For a sparse volume, changes to
1520 are not reflected in the
1521 .Sy refreservation .
1522 A volume that is not sparse is said to be "thick provisioned".
1523 A sparse volume can become thick provisioned by setting
1527 .It Sy volmode Ns = Ns Cm default | geom | dev | none
1528 This property specifies how volumes should be exposed to the OS.
1533 providers, providing maximal functionality.
1536 exposes volumes only as cdev device in devfs.
1537 Such volumes can be accessed only as raw disk device files, i.e. they
1538 can not be partitioned, mounted, participate in RAIDs, etc, but they
1539 are faster, and in some use scenarios with untrusted consumer, such as
1540 NAS or VM storage, can be more safe.
1541 Volumes with property set to
1543 are not exposed outside ZFS, but can be snapshoted, cloned, replicated, etc,
1544 that can be suitable for backup purposes.
1547 means that volumes exposition is controlled by system-wide sysctl/tunable
1548 .Va vfs.zfs.vol.mode ,
1554 are encoded as 1, 2 and 3 respectively.
1555 The default values is
1557 This property can be changed any time, but so far it is processed only
1558 during volume creation and pool import.
1559 .It Sy vscan Ns = Ns Cm off | on
1562 property is currently not supported on
1564 .It Sy xattr Ns = Ns Cm off | on
1567 property is currently not supported on
1569 .It Sy jailed Ns = Ns Cm off | on
1570 Controls whether the dataset is managed from a jail. See the
1572 section for more information. The default value is
1576 The following three properties cannot be changed after the file system is
1577 created, and therefore, should be set when the file system is created. If the
1578 properties are not set with the
1582 commands, these properties are inherited from the parent dataset. If the parent
1583 dataset lacks these properties due to having been created prior to these
1584 features being supported, the new file system will have the default values for
1587 .It Sy casesensitivity Ns = Ns Cm sensitive | insensitive | mixed
1588 Indicates whether the file name matching algorithm used by the file system
1589 should be case-sensitive, case-insensitive, or allow a combination of both
1590 styles of matching. The default value for the
1594 Traditionally, UNIX and POSIX file systems have case-sensitive file names.
1600 property indicates that the
1601 file system can support requests for both case-sensitive and case-insensitive
1603 .It Sy normalization Ns = Ns Cm none | formC | formD | formKC | formKD
1604 Indicates whether the file system should perform a
1606 normalization of file names whenever two file names are compared, and which
1607 normalization algorithm should be used. File names are always stored
1608 unmodified, names are normalized as part of any comparison process. If this
1609 property is set to a legal value other than
1613 property was left unspecified, the
1615 property is automatically set to
1617 The default value of the
1621 This property cannot be changed after the file system is created.
1622 .It Sy utf8only Ns = Ns Cm on | off
1623 Indicates whether the file system should reject file names that include
1624 characters that are not present in the
1626 character code set. If this property is explicitly set to
1628 the normalization property must either not be explicitly set or be set to
1630 The default value for the
1634 This property cannot be changed after the file system is created.
1638 .Sy casesensitivity , normalization , No and Sy utf8only
1639 properties are also new permissions that can be assigned to non-privileged
1642 delegated administration feature.
1643 .Ss Temporary Mount Point Properties
1644 When a file system is mounted, either through
1646 for legacy mounts or the
1648 command for normal file systems, its mount options are set according to its
1649 properties. The correlation between properties and mount options is as follows:
1650 .Bl -column -offset 4n "PROPERTY" "MOUNT OPTION"
1651 .It "PROPERTY MOUNT OPTION"
1652 .It "atime atime/noatime"
1653 .It "exec exec/noexec"
1654 .It "readonly ro/rw"
1655 .It "setuid suid/nosuid"
1658 In addition, these options can be set on a per-mount basis using the
1660 option, without affecting the property that is stored on disk. The values
1661 specified on the command line override the values stored in the dataset. These
1662 properties are reported as "temporary" by the
1664 command. If the properties are changed while the dataset is mounted, the new
1665 setting overrides any temporary settings.
1667 In addition to the standard native properties,
1669 supports arbitrary user properties. User properties have no effect on
1671 behavior, but applications or administrators can use them to annotate datasets
1672 (file systems, volumes, and snapshots).
1674 User property names must contain a colon
1676 character to distinguish them from native properties. They may contain
1677 lowercase letters, numbers, and the following punctuation characters: colon
1685 The expected convention is that the property name is divided into two portions
1687 .Em module Ns Sy \&: Ns Em property ,
1688 but this namespace is not enforced by
1690 User property names can be at most 256 characters, and cannot begin with a dash
1693 When making programmatic use of user properties, it is strongly suggested to
1698 component of property names to reduce the chance that two
1699 independently-developed packages use the same property name for different
1700 purposes. Property names beginning with
1702 are reserved for use by Sun Microsystems.
1704 The values of user properties are arbitrary strings, are always inherited, and
1705 are never validated. All of the commands that operate on properties
1712 can be used to manipulate both native properties and user properties. Use the
1714 command to clear a user property. If the property is not defined in any parent
1715 dataset, it is removed entirely. Property values are limited to 1024
1718 All subcommands that modify state are logged persistently to the pool in their
1726 Displays a help message.
1731 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
1737 file system. The file system is automatically mounted according to the
1739 property inherited from the parent.
1740 .Bl -tag -width indent
1742 Creates all the non-existing parent datasets. Datasets created in this manner
1743 are automatically mounted according to the
1745 property inherited from their parent. Any property specified on the command
1748 option is ignored. If the target filesystem already exists, the operation
1749 completes successfully.
1751 Newly created file system is not mounted.
1752 .It Fl o Ar property Ns = Ns Ar value
1753 Sets the specified property as if the command
1754 .Qq Nm Cm set Ar property Ns = Ns Ar value
1755 was invoked at the same time the dataset was created. Any editable
1757 property can also be set at creation time. Multiple
1759 options can be specified. An error results if the same property is specified in
1768 .Op Fl b Ar blocksize
1769 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
1774 Creates a volume of the given size. The volume is exported as a block device in
1775 .Pa /dev/zvol/path ,
1778 is the name of the volume in the
1780 namespace. The size represents the logical size as exported by the device. By
1781 default, a reservation of equal size is created.
1784 is automatically rounded up to the nearest 128 Kbytes to ensure that
1785 the volume has an integral number of blocks regardless of
1787 .Bl -tag -width indent
1789 Creates all the non-existing parent datasets. Datasets created in this manner
1790 are automatically mounted according to the
1792 property inherited from their parent. Any property specified on the command
1795 option is ignored. If the target filesystem already exists, the operation
1796 completes successfully.
1798 Creates a sparse volume with no reservation. See
1801 .Qq Sx Native Properties
1802 section for more information about sparse volumes.
1803 .It Fl b Ar blocksize
1805 .Fl o Cm volblocksize Ns = Ns Ar blocksize .
1806 If this option is specified in conjunction with
1807 .Fl o Cm volblocksize ,
1808 the resulting behavior is undefined.
1809 .It Fl o Ar property Ns = Ns Ar value
1810 Sets the specified property as if the
1811 .Qq Nm Cm set Ar property Ns = Ns Ar value
1812 command was invoked at the same time the dataset was created. Any editable
1814 property can also be set at creation time. Multiple
1816 options can be specified. An error results if the same property is specified in
1825 .Ar filesystem Ns | Ns Ar volume
1828 Destroys the given dataset. By default, the command unshares any file systems
1829 that are currently shared, unmounts any file systems that are currently
1830 mounted, and refuses to destroy a dataset that has active dependents (children
1832 .Bl -tag -width indent
1834 Recursively destroy all children.
1836 Recursively destroy all dependents, including cloned file systems outside the
1839 Force an unmount of any file systems using the
1840 .Qq Nm Cm unmount Fl f
1841 command. This option has no effect on non-file systems or unmounted file
1844 Do a dry-run ("No-op") deletion. No data will be deleted. This is useful in
1845 conjunction with the
1849 flags to determine what data would be deleted.
1851 Print machine-parsable verbose information about the deleted data.
1853 Print verbose information about the deleted data.
1856 Extreme care should be taken when applying either the
1860 options, as they can destroy large portions of a pool and cause unexpected
1861 behavior for mounted file systems in use.
1868 .Op % Ns Ar snapname
1873 The given snapshots are destroyed immediately if and only if the
1877 option would have destroyed it. Such immediate destruction would occur, for
1878 example, if the snapshot had no clones and the user-initiated reference count
1881 If a snapshot does not qualify for immediate destruction, it is marked for
1882 deferred deletion. In this state, it exists as a usable, visible snapshot until
1883 both of the preconditions listed above are met, at which point it is destroyed.
1885 An inclusive range of snapshots may be specified by separating the
1886 first and last snapshots with a percent sign
1888 The first and/or last snapshots may be left blank, in which case the
1889 filesystem's oldest or newest snapshot will be implied.
1892 (or ranges of snapshots) of the same filesystem or volume may be specified
1893 in a comma-separated list of snapshots.
1894 Only the snapshot's short name (the
1897 should be specified when using a range or comma-separated list to identify
1899 .Bl -tag -width indent
1901 Destroy (or mark for deferred deletion) all snapshots with this name in
1902 descendent file systems.
1904 Recursively destroy all clones of these snapshots, including the clones,
1905 snapshots, and children.
1906 If this flag is specified, the
1908 flag will have no effect.
1910 Do a dry-run ("No-op") deletion. No data will be deleted. This is useful in
1911 conjunction with the
1915 flags to determine what data would be deleted.
1917 Print machine-parsable verbose information about the deleted data.
1919 Print verbose information about the deleted data.
1921 Defer snapshot deletion.
1924 Extreme care should be taken when applying either the
1928 options, as they can destroy large portions of a pool and cause unexpected
1929 behavior for mounted file systems in use.
1933 .Ar filesystem Ns | Ns Ar volume Ns # Ns Ar bookmark
1936 The given bookmark is destroyed.
1939 .Cm snapshot Ns | Ns Cm snap
1941 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
1942 .Ar filesystem@snapname Ns | Ns volume@snapname
1943 .Ar filesystem@snapname Ns | Ns volume@snapname Ns ...
1946 Creates snapshots with the given names. All previous modifications by
1947 successful system calls to the file system are part of the snapshots.
1948 Snapshots are taken atomically, so that all snapshots correspond to the same
1949 moment in time. See the
1951 section for details.
1952 .Bl -tag -width indent
1954 Recursively create snapshots of all descendent datasets
1955 .It Fl o Ar property Ns = Ns Ar value
1956 Sets the specified property; see
1967 Roll back the given dataset to a previous snapshot. When a dataset is rolled
1968 back, all data that has changed since the snapshot is discarded, and the
1969 dataset reverts to the state at the time of the snapshot. By default, the
1970 command refuses to roll back to a snapshot other than the most recent one. In
1971 order to do so, all intermediate snapshots and bookmarks must be destroyed
1978 options do not recursively destroy the child snapshots of a
1980 Only direct snapshots of the specified filesystem
1981 are destroyed by either of these options.
1982 To completely roll back a
1983 recursive snapshot, you must rollback the individual child snapshots.
1984 .Bl -tag -width indent
1986 Destroy any snapshots and bookmarks more recent than the one specified.
1988 Destroy any more recent snapshots and bookmarks, as well as any clones of those
1993 option to force an unmount of any clone file systems that are to be destroyed.
1999 .Oo Fl o Ar property Ns = Ns Ar value Oc Ns ...
2000 .Ar snapshot filesystem Ns | Ns Ar volume
2003 Creates a clone of the given snapshot. See the
2005 section for details. The target dataset can be located anywhere in the
2007 hierarchy, and is created as the same type as the original.
2008 .Bl -tag -width indent
2010 Creates all the non-existing parent datasets. Datasets created in this manner
2011 are automatically mounted according to the
2013 property inherited from their parent. If the target filesystem or volume
2014 already exists, the operation completes successfully.
2015 .It Fl o Ar property Ns = Ns Ar value
2016 Sets the specified property; see
2023 .Ar clone-filesystem
2026 Promotes a clone file system to no longer be dependent on its "origin"
2027 snapshot. This makes it possible to destroy the file system that the clone was
2028 created from. The clone parent-child dependency relationship is reversed, so
2029 that the origin file system becomes a clone of the specified file system.
2031 The snapshot that was cloned, and any snapshots previous to this snapshot, are
2032 now owned by the promoted clone. The space they use moves from the origin file
2033 system to the promoted clone, so enough space must be available to accommodate
2034 these snapshots. No new space is consumed by this operation, but the space
2035 accounting is adjusted. The promoted clone must not have any conflicting
2036 snapshot names of its own. The
2038 subcommand can be used to rename any conflicting snapshots.
2043 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
2044 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
2051 .Ar filesystem Ns | Ns Ar volume
2052 .Ar filesystem Ns | Ns Ar volume
2059 .Ar filesystem filesystem
2062 Renames the given dataset. The new target can be located anywhere in the
2064 hierarchy, with the exception of snapshots. Snapshots can only be renamed
2065 within the parent file system or volume. When renaming a snapshot, the parent
2066 file system of the snapshot does not need to be specified as part of the second
2067 argument. Renamed file systems can inherit new mount points, in which case they
2068 are unmounted and remounted at the new mount point.
2069 .Bl -tag -width indent
2071 Creates all the nonexistent parent datasets. Datasets created in this manner
2072 are automatically mounted according to the
2074 property inherited from their parent.
2076 Do not remount file systems during rename. If a file system's
2082 file system is not unmounted even if this option is not given.
2084 Force unmount any filesystems that need to be unmounted in the process.
2085 This flag has no effect if used together with the
2093 .Ar snapshot snapshot
2096 Recursively rename the snapshots of all descendent datasets. Snapshots are the
2097 only dataset that can be renamed recursively.
2101 .Ar bookmark bookmark
2104 Renames the given bookmark.
2105 Bookmarks can only be renamed within the parent file system or volume.
2106 When renaming a bookmark, the parent file system or volume of the bookmark
2107 does not need to be specified as part of the second argument.
2111 .Op Fl r Ns | Ns Fl d Ar depth
2113 .Op Fl o Ar property Ns Oo , Ns Ar property Oc Ns ...
2114 .Op Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2115 .Oo Fl s Ar property Oc Ns ...
2116 .Oo Fl S Ar property Oc Ns ...
2117 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns ...
2120 Lists the property information for the given datasets in tabular form. If
2121 specified, you can list property information by the absolute pathname or the
2122 relative pathname. By default, all file systems and volumes are displayed.
2123 Snapshots are displayed if the
2129 The following fields are displayed,
2130 .Sy name , used , available , referenced , mountpoint .
2131 .Bl -tag -width indent
2133 Recursively display any children of the dataset on the command line.
2135 Recursively display any children of the dataset, limiting the recursion to
2139 will display only the dataset and its direct children.
2141 Used for scripting mode. Do not print headers and separate fields by a single
2142 tab instead of arbitrary white space.
2144 Display numbers in parsable (exact) values.
2145 .It Fl o Ar property Ns Oo , Ns Ar property Oc Ns ...
2146 A comma-separated list of properties to display. The property must be:
2147 .Bl -bullet -offset 2n
2149 One of the properties described in the
2150 .Qq Sx Native Properties
2157 to display the dataset name
2161 to display space usage properties on file systems and volumes. This is a
2162 shortcut for specifying
2164 .Sy name,avail,used,usedsnap,usedds,usedrefreserv,usedchild
2166 .Sy filesystem,volume
2169 .It Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2170 A comma-separated list of types to display, where
2173 .Sy filesystem , snapshot , snap , volume , bookmark , No or Sy all .
2174 For example, specifying
2176 displays only snapshots.
2177 .It Fl s Ar property
2178 A property for sorting the output by column in ascending order based on the
2179 value of the property. The property must be one of the properties described in
2182 section, or the special value
2184 to sort by the dataset name. Multiple properties can be specified at one time
2187 property options. Multiple
2189 options are evaluated from left to right in decreasing order of importance.
2191 The following is a list of sorting criteria:
2192 .Bl -bullet -offset 2n
2194 Numeric types sort in numeric order.
2196 String types sort in alphabetical order.
2198 Types inappropriate for a row sort that row to the literal bottom, regardless
2199 of the specified ordering.
2201 If no sorting options are specified the existing behavior of
2205 .It Fl S Ar property
2208 option, but sorts by property in descending order.
2213 .Ar property Ns = Ns Ar value Oo Ar property Ns = Ns Ar value Oc Ns ...
2214 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
2217 Sets the property or list of properties to the given value(s) for each dataset.
2218 Only some properties can be edited. See the "Properties" section for more
2219 information on what properties can be set and acceptable values. Numeric values
2220 can be specified as exact values, or in a human-readable form with a suffix of
2221 .Sy B , K , M , G , T , P , E , Z
2222 (for bytes, kilobytes, megabytes, gigabytes, terabytes, petabytes, exabytes, or
2223 zettabytes, respectively). User properties can be set on snapshots. For more
2224 information, see the
2225 .Qq Sx User Properties
2230 .Op Fl r Ns | Ns Fl d Ar depth
2232 .Op Fl o Ar all | field Ns Oo , Ns Ar field Oc Ns ...
2233 .Op Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2234 .Op Fl s Ar source Ns Oo , Ns Ar source Oc Ns ...
2235 .Ar all | property Ns Oo , Ns Ar property Oc Ns ...
2236 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns | Ns Ar bookmark Ns ...
2239 Displays properties for the given datasets. If no datasets are specified, then
2240 the command displays properties for all datasets on the system. For each
2241 property, the following columns are displayed:
2243 .Bl -hang -width "property" -offset indent -compact
2251 Property source. Can either be local, default, temporary, inherited, received,
2256 All columns except the
2258 column are displayed by default. The columns to display can be specified
2261 option. This command takes a comma-separated list of properties as described in
2263 .Qq Sx Native Properties
2265 .Qq Sx User Properties
2270 can be used to display all properties that apply to the given dataset's type
2271 (filesystem, volume, snapshot, or bookmark).
2272 .Bl -tag -width indent
2274 Recursively display properties for any children.
2276 Recursively display any children of the dataset, limiting the recursion to
2280 will display only the dataset and its direct children.
2282 Display output in a form more easily parsed by scripts. Any headers are
2283 omitted, and fields are explicitly separated by a single tab instead of an
2284 arbitrary amount of space.
2286 Display numbers in parsable (exact) values.
2287 .It Fl o Cm all | Ar field Ns Oo , Ns Ar field Oc Ns ...
2288 A comma-separated list of columns to display. Supported values are
2289 .Sy name,property,value,received,source .
2291 .Sy name,property,value,source .
2294 specifies all columns.
2295 .It Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2296 A comma-separated list of types to display, where
2299 .Sy filesystem , snapshot , volume , No or Sy all .
2300 For example, specifying
2302 displays only snapshots.
2303 .It Fl s Ar source Ns Oo , Ns Ar source Oc Ns ...
2304 A comma-separated list of sources to display. Those properties coming from a
2305 source other than those in this list are ignored. Each source must be one of
2307 .Sy local,default,inherited,temporary,received,none .
2308 The default value is all sources.
2315 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns ...
2318 Clears the specified property, causing it to be inherited from an ancestor,
2319 restored to default if no ancestor has the property set, or with the
2321 option reverted to the received value if one exists.
2324 section for a listing of default values, and details on which properties can be
2326 .Bl -tag -width indent
2328 Recursively inherit the given property for all children.
2330 Revert the property to the received value if one exists; otherwise operate as
2333 option was not specified.
2338 .Ar filesystem Ns | Ns Ar volume
2341 Remap the indirect blocks in the given filesystem or volume so that they no
2342 longer reference blocks on previously removed vdevs and we can eventually
2343 shrink the size of the indirect mapping objects for the previously removed
2344 vdevs. Note that remapping all blocks might not be possible and that
2345 references from snapshots will still exist and cannot be remapped.
2352 Displays a list of file systems that are not the most recent version.
2353 .Bl -tag -width indent
2357 filesystem versions supported by the current software. The current
2359 filesystem version and all previous supported versions are displayed, along
2360 with an explanation of the features provided with each version.
2367 .Fl a | Ar filesystem
2370 Upgrades file systems to a new on-disk version. Once this is done, the file
2371 systems will no longer be accessible on systems running older versions of the
2374 streams generated from new snapshots of these file systems cannot be accessed
2375 on systems running older versions of the software.
2377 In general, the file system version is independent of the pool version. See
2379 for information on the
2380 .Nm zpool Cm upgrade
2383 In some cases, the file system version and the pool version are interrelated
2384 and the pool version must be upgraded before the file system version can be
2386 .Bl -tag -width indent
2388 Upgrade the specified file system and all descendent file systems.
2390 Upgrade to the specified
2394 flag is not specified, this command upgrades to the most recent version. This
2395 option can only be used to increase the version number, and only up to the most
2396 recent version supported by this software.
2398 Upgrade all file systems on all imported pools.
2400 Upgrade the specified file system.
2406 .Op Fl o Ar field Ns Oo , Ns Ar field Oc Ns ...
2407 .Oo Fl s Ar field Oc Ns ...
2408 .Oo Fl S Ar field Oc Ns ...
2409 .Op Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2410 .Ar filesystem Ns | Ns Ar snapshot
2413 Displays space consumed by, and quotas on, each user in the specified
2414 filesystem or snapshot. This corresponds to the
2415 .Sy userused@ Ns Ar user
2417 .Sy userquota@ Ns Ar user
2419 .Bl -tag -width indent
2421 Print numeric ID instead of user/group name.
2423 Do not print headers, use tab-delimited output.
2425 Use exact (parsable) numeric output.
2426 .It Fl o Ar field Ns Oo , Ns Ar field Oc Ns ...
2427 Display only the specified fields from the following set:
2428 .Sy type,name,used,quota .
2429 The default is to display all fields.
2431 Sort output by this field. The
2435 flags may be specified multiple times to sort first by one field, then by
2436 another. The default is
2437 .Fl s Cm type Fl s Cm name .
2439 Sort by this field in reverse order. See
2441 .It Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2442 Print only the specified types from the following set:
2443 .Sy all,posixuser,smbuser,posixgroup,smbgroup .
2446 .Fl t Cm posixuser,smbuser .
2448 The default can be changed to include group types.
2450 Translate SID to POSIX ID. This flag currently has no effect on
2457 .Op Fl o Ar field Ns Oo , Ns Ar field Oc Ns ...
2458 .Oo Fl s Ar field Oc Ns ...
2459 .Oo Fl S Ar field Oc Ns ...
2460 .Op Fl t Ar type Ns Oo , Ns Ar type Oc Ns ...
2461 .Ar filesystem Ns | Ns Ar snapshot
2464 Displays space consumed by, and quotas on, each group in the specified
2465 filesystem or snapshot. This subcommand is identical to
2466 .Qq Nm Cm userspace ,
2467 except that the default types to display are
2468 .Fl t Sy posixgroup,smbgroup .
2476 file systems currently mounted.
2477 .Bl -tag -width indent
2484 .Op Fl o Ar property Ns Oo , Ns Ar property Oc Ns ...
2485 .Fl a | Ar filesystem
2491 .Bl -tag -width indent
2493 Report mount progress.
2495 Perform an overlay mount. Overlay mounts are not supported on
2497 .It Fl o Ar property Ns Oo , Ns Ar property Oc Ns ...
2498 An optional, comma-separated list of mount options to use temporarily for the
2499 duration of the mount. See the
2500 .Qq Sx Temporary Mount Point Properties
2501 section for details.
2506 This command may be executed on
2510 For more information, see variable
2515 Mount the specified filesystem.
2519 .Cm unmount Ns | Ns Cm umount
2521 .Fl a | Ar filesystem Ns | Ns Ar mountpoint
2524 Unmounts currently mounted
2527 .Bl -tag -width indent
2529 Forcefully unmount the file system, even if it is currently in use.
2531 Unmount all available
2534 .It Ar filesystem | mountpoint
2535 Unmount the specified filesystem. The command can also be given a path to a
2537 file system mount point on the system.
2542 .Fl a | Ar filesystem
2547 file systems that have the
2550 .Bl -tag -width indent
2554 file systems that have the
2557 This command may be executed on
2561 For more information, see variable
2566 Share the specified filesystem according to the
2568 property. File systems are shared when the
2575 .Fl a | Ar filesystem Ns | Ns Ar mountpoint
2580 file systems that have the
2583 .Bl -tag -width indent
2587 file systems that have the
2590 This command may be executed on
2594 For more information, see variable
2598 .It Ar filesystem | mountpoint
2599 Unshare the specified filesystem. The command can also be given a path to a
2601 file system shared on the system.
2610 Creates a bookmark of the given snapshot.
2611 Bookmarks mark the point in time
2612 when the snapshot was created, and can be used as the incremental source for
2617 This feature must be enabled to be used.
2619 .Xr zpool-features 7
2620 for details on ZFS feature flags and the
2627 .Op Fl i Ar snapshot | Fl I Ar snapshot
2631 Creates a stream representation of the last
2633 argument (not part of
2637 which is written to standard output. The output can be redirected to
2638 a file or to a different system (for example, using
2640 By default, a full stream is generated.
2641 .Bl -tag -width indent
2642 .It Fl i Ar snapshot
2643 Generate an incremental stream from the first
2644 .Ar snapshot Pq the incremental source
2646 .Ar snapshot Pq the incremental target .
2647 The incremental source can be specified as the last component of the
2649 .Pq the Em @ No character and following
2651 it is assumed to be from the same file system as the incremental target.
2653 If the destination is a clone, the source may be the origin snapshot, which
2654 must be fully specified (for example,
2655 .Cm pool/fs@origin ,
2658 .It Fl I Ar snapshot
2659 Generate a stream package that sends all intermediary snapshots from the first
2666 .Ic -i @a fs@b; -i @b fs@c; -i @c fs@d .
2668 source may be specified as with the
2671 .It Fl R, -replicate
2672 Generate a replication stream package, which will replicate the specified
2673 filesystem, and all descendent file systems, up to the named snapshot. When
2674 received, all properties, snapshots, descendent file systems, and clones are
2681 flags are used in conjunction with the
2683 flag, an incremental replication stream is generated. The current values of
2684 properties, and current snapshot and file system names are set when the stream
2687 flag is specified when this stream is received, snapshots and file systems that
2688 do not exist on the sending side are destroyed.
2690 Generate a deduplicated stream. Blocks which would have been sent multiple
2691 times in the send stream will only be sent once. The receiving system must
2692 also support this feature to receive a deduplicated stream. This flag can
2693 be used regardless of the dataset's
2695 property, but performance will be much better if the filesystem uses a
2696 dedup-capable checksum (eg.
2698 .It Fl L, -large-block
2699 Generate a stream which may contain blocks larger than 128KB.
2701 has no effect if the
2703 pool feature is disabled, or if the
2705 property of this filesystem has never been set above 128KB.
2706 The receiving system must have the
2708 pool feature enabled as well.
2710 .Xr zpool-features 7
2711 for details on ZFS feature flags and the
2715 Generate a more compact stream by using WRITE_EMBEDDED records for blocks
2716 which are stored more compactly on disk by the
2720 This flag has no effect if the
2724 The receiving system must have the
2730 feature is active on the sending system,
2731 then the receiving system must have that feature enabled as well.
2733 .Xr zpool-features 7
2734 for details on ZFS feature flags and the
2737 .It Fl c, -compressed
2738 Generate a more compact stream by using compressed WRITE records for blocks
2739 which are compressed on disk and in memory (see the
2741 property for details).
2744 feature is active on the sending system, then the receiving system must have that
2745 feature enabled as well. If the
2747 feature is enabled on the sending system but the
2749 option is not supplied in conjunction with
2751 then the data will be decompressed before sending so it can be split
2752 into smaller block sizes.
2754 Include the dataset's properties in the stream. This flag is implicit when
2756 is specified. The receiving system must also support this feature.
2758 Do a dry-run ("No-op") send. Do not generate any actual send data. This is
2759 useful in conjunction with the
2763 flags to determine what data will be sent.
2764 In this case, the verbose output will be written to
2765 standard output (contrast with a non-dry-run, where the stream is written
2766 to standard output and the verbose output goes to standard error).
2768 Print machine-parsable verbose information about the stream package generated.
2770 Print verbose information about the stream package generated.
2771 This information includes a per-second report of how much data has been sent.
2773 Set the process title to a per-second report of how much data has been sent.
2776 The format of the stream is committed. You will be able to receive your streams
2777 on future versions of
2783 .Op Fl i Ar snapshot Ns | Ns Ar bookmark
2784 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
2787 Generate a send stream, which may be of a filesystem, and may be
2788 incremental from a bookmark.
2789 If the destination is a filesystem or volume,
2790 the pool must be read-only, or the filesystem must not be mounted.
2792 stream generated from a filesystem or volume is received, the default snapshot
2795 .Bl -tag -width indent
2796 .It Fl i Ar snapshot Ns | Ns Ar bookmark
2797 Generate an incremental send stream.
2798 The incremental source must be an earlier
2799 snapshot in the destination's history.
2800 It will commonly be an earlier
2801 snapshot in the destination's filesystem, in which case it can be
2802 specified as the last component of the name
2803 .Pq the Em # No or Em @ No character and following .
2805 If the incremental target is a clone, the incremental source can
2806 be the origin snapshot, or an earlier snapshot in the origin's filesystem,
2807 or the origin's origin, etc.
2812 Do not generate any actual send data.
2813 This is useful in conjunction with the
2817 flags to determine what data will be sent.
2818 In this case, the verbose output will be written to standard output
2819 .Po contrast with a non-dry-run, where the stream is written to standard output
2820 and the verbose output goes to standard error
2823 Print verbose information about the stream package generated.
2824 This information includes a per-second report of how much data has been sent.
2825 .It Fl L, -large-block
2826 Generate a stream which may contain blocks larger than 128KB.
2828 has no effect if the
2830 pool feature is disabled, or if the
2832 property of this filesystem has never been set above 128KB.
2833 The receiving system must have the
2835 pool feature enabled as well.
2837 .Xr zpool-features 7
2838 for details on ZFS feature flags and the
2842 Print machine-parsable verbose information about the stream package generated.
2843 .It Fl c, -compressed
2844 Generate a more compact stream by using compressed WRITE records for blocks
2845 which are compressed on disk and in memory (see the
2847 property for details). If the
2849 feature is active on the sending system, then the receiving system must have
2850 that feature enabled as well. If the
2852 feature is enabled on the sending system but the
2854 option is not supplied in conjunction with
2856 then the data will be decompressed before sending so it can be split
2857 into smaller block sizes.
2859 Generate a more compact stream by using WRITE_EMBEDDED records for blocks
2860 which are stored more compactly on disk by the
2864 This flag has no effect if the
2868 The receiving system must have the
2874 feature is active on the sending system,
2875 then the receiving system must have that feature enabled as well.
2877 .Xr zpool-features 7
2878 for details on ZFS feature flags and the
2887 .Ar receive_resume_token
2889 Creates a send stream which resumes an interrupted receive. The
2890 .Ar receive_resume_token
2891 is the value of this property on the filesystem
2892 or volume that was being received into. See the documentation for
2897 .Cm receive Ns | Ns Cm recv
2899 .Op Fl o Sy origin Ns = Ns Ar snapshot
2900 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot
2904 .Cm receive Ns | Ns Cm recv
2907 .Op Fl o Sy origin Ns = Ns Ar snapshot
2911 Creates a snapshot whose contents are as specified in the stream provided on
2912 standard input. If a full stream is received, then a new file system is created
2913 as well. Streams are created using the
2915 subcommand, which by default creates a full stream.
2917 can be used as an alias for
2920 If an incremental stream is received, then the destination file system must
2921 already exist, and its most recent snapshot must match the incremental stream's
2924 the destination device link is destroyed and recreated, which means the
2926 cannot be accessed during the
2930 When a snapshot replication package stream that is generated by using the
2932 command is received, any snapshots that do not exist on the sending location
2933 are destroyed by using the
2934 .Qq Nm Cm destroy Fl d
2937 The name of the snapshot (and file system, if a full stream is received) that
2938 this subcommand creates depends on the argument type and the
2944 If the argument is a snapshot name, the specified
2946 is created. If the argument is a file system or volume name, a snapshot with
2947 the same name as the sent snapshot is created within the specified
2955 option is specified, the snapshot name is determined by appending the sent
2956 snapshot's name to the specified
2960 option is specified, all but the pool name of the sent snapshot path is
2961 appended (for example,
2963 appended from sent snapshot
2967 option is specified, only the tail of the sent snapshot path is appended (for
2970 appended from sent snapshot
2974 any file systems needed to replicate the path of the sent snapshot are created
2975 within the specified file system.
2976 .Bl -tag -width indent
2978 Use the full sent snapshot path without the first element (without pool name)
2979 to determine the name of the new snapshot as described in the paragraph above.
2981 Use only the last element of the sent snapshot path to determine the name of
2982 the new snapshot as described in the paragraph above.
2984 File system that is associated with the received stream is not mounted.
2986 Print verbose information about the stream and the time required to perform the
2989 Do not actually receive the stream. This can be useful in conjunction with the
2991 option to verify the name the receive operation would use.
2992 .It Fl o Sy origin Ns = Ns Ar snapshot
2993 Forces the stream to be received as a clone of the given snapshot.
2994 If the stream is a full send stream, this will create the filesystem
2995 described by the stream as a clone of the specified snapshot. Which
2996 snapshot was specified will not affect the success or failure of the
2997 receive, as long as the snapshot does exist. If the stream is an
2998 incremental send stream, all the normal verification will be performed.
3000 Force a rollback of the file system to the most recent snapshot before
3001 performing the receive operation. If receiving an incremental replication
3002 stream (for example, one generated by
3003 .Qq Nm Cm send Fl R Bro Fl i | Fl I Brc ) ,
3004 destroy snapshots and file systems that do not exist on the sending side.
3006 If the receive is interrupted, save the partially received state, rather
3007 than deleting it. Interruption may be due to premature termination of
3009 .Po e.g. due to network failure or failure of the remote system
3010 if the stream is being read over a network connection
3012 a checksum error in the stream, termination of the
3014 process, or unclean shutdown of the system.
3016 The receive can be resumed with a stream generated by
3017 .Nm zfs Cm send Fl t Ar token ,
3021 .Sy receive_resume_token
3022 property of the filesystem or volume which is received into.
3024 To use this flag, the storage pool must have the
3025 .Sy extensible_dataset
3026 feature enabled. See
3027 .Xr zpool-features 5
3028 for details on ZFS feature flags.
3032 .Cm receive Ns | Ns Cm recv
3034 .Ar filesystem Ns | Ns Ar volume
3036 Abort an interrupted
3037 .Nm zfs Cm receive Fl s ,
3038 deleting its saved partially received state.
3042 .Ar filesystem Ns | Ns Ar volume
3045 Displays permissions that have been delegated on the specified filesystem or
3046 volume. See the other forms of
3048 for more information.
3053 .Ar user Ns | Ns Ar group Ns Oo Ns , Ns Ar user Ns | Ns Ar group Oc Ns ...
3054 .Ar perm Ns | Ns Ar @setname Ns
3055 .Oo Ns , Ns Ar perm Ns | Ns Ar @setname Oc Ns ...
3056 .Ar filesystem Ns | Ns Ar volume
3062 .Fl e Ns | Ns Cm everyone
3063 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
3065 .Ar filesystem Ns | Ns Ar volume
3070 administration permission for the file systems to non-privileged users.
3071 .Bl -tag -width indent
3074 .Ar user Ns | Ns Ar group Ns Oo , Ar user Ns | Ns Ar group Oc Ns ...
3076 Specifies to whom the permissions are delegated. Multiple entities can be
3077 specified as a comma-separated list. If neither of the
3079 options are specified, then the argument is interpreted preferentially as the
3082 then as a user name, and lastly as a group name. To specify
3083 a user or group named
3089 options. To specify a group with the same name as a user, use the
3092 .It Op Fl e Ns | Ns Cm everyone
3093 Specifies that the permissions be delegated to
3096 .Ar perm Ns | Ns Ar @setname Ns Oo , Ns Ar perm Ns | Ns Ar @setname Oc Ns ...
3098 The permissions to delegate. Multiple permissions
3099 may be specified as a comma-separated list. Permission names are the same as
3101 subcommand and property names. See the property list below. Property set names,
3102 which begin with an at sign
3104 may be specified. See the
3106 form below for details.
3109 .Ar filesystem Ns | Ns Ar volume
3111 Specifies where the permissions are delegated. If neither of the
3113 options are specified, or both are, then the permissions are allowed for the
3114 file system or volume, and all of its descendents. If only the
3116 option is used, then is allowed "locally" only for the specified file system.
3119 option is used, then is allowed only for the descendent file systems.
3122 Permissions are generally the ability to use a
3124 subcommand or change a
3126 property. The following permissions are available:
3127 .Bl -column -offset 4n "secondarycache" "subcommand"
3128 .It NAME Ta TYPE Ta NOTES
3129 .It allow Ta subcommand Ta Must Xo
3130 also have the permission that is being allowed
3132 .It clone Ta subcommand Ta Must Xo
3133 also have the 'create' ability and 'mount' ability in the origin file system
3135 .It create Ta subcommand Ta Must also have the 'mount' ability
3136 .It destroy Ta subcommand Ta Must also have the 'mount' ability
3137 .It diff Ta subcommand Ta Allows lookup of paths within a dataset given an
3138 object number, and the ability to create snapshots necessary to 'zfs diff'
3139 .It hold Ta subcommand Ta Allows adding a user hold to a snapshot
3140 .It mount Ta subcommand Ta Allows mount/umount of Tn ZFS No datasets
3141 .It promote Ta subcommand Ta Must Xo
3142 also have the 'mount' and 'promote' ability in the origin file system
3144 .It receive Ta subcommand Ta Must also have the 'mount' and 'create' ability
3145 .It release Ta subcommand Ta Allows Xo
3146 releasing a user hold which might destroy the snapshot
3148 .It rename Ta subcommand Ta Must Xo
3149 also have the 'mount' and 'create' ability in the new parent
3151 .It rollback Ta subcommand Ta Must also have the 'mount' ability
3152 .It send Ta subcommand
3153 .It share Ta subcommand Ta Allows Xo
3154 sharing file systems over the
3158 .It snapshot Ta subcommand Ta Must also have the 'mount' ability
3159 .It groupquota Ta other Ta Allows accessing any groupquota@... property
3160 .It groupused Ta other Ta Allows reading any groupused@... property
3161 .It userprop Ta other Ta Allows changing any user property
3162 .It userquota Ta other Ta Allows accessing any userquota@... property
3163 .It userused Ta other Ta Allows reading any userused@... property
3164 .It aclinherit Ta property
3165 .It aclmode Ta property
3166 .It atime Ta property
3167 .It canmount Ta property
3168 .It casesensitivity Ta property
3169 .It checksum Ta property
3170 .It compression Ta property
3171 .It copies Ta property
3172 .It dedup Ta property
3173 .It devices Ta property
3174 .It exec Ta property
3175 .It filesystem_limit Ta property
3176 .It logbias Ta property
3177 .It jailed Ta property
3178 .It mlslabel Ta property
3179 .It mountpoint Ta property
3180 .It nbmand Ta property
3181 .It normalization Ta property
3182 .It primarycache Ta property
3183 .It quota Ta property
3184 .It readonly Ta property
3185 .It recordsize Ta property
3186 .It refquota Ta property
3187 .It refreservation Ta property
3188 .It reservation Ta property
3189 .It secondarycache Ta property
3190 .It setuid Ta property
3191 .It sharenfs Ta property
3192 .It sharesmb Ta property
3193 .It snapdir Ta property
3194 .It snapshot_limit Ta property
3195 .It sync Ta property
3196 .It utf8only Ta property
3197 .It version Ta property
3198 .It volblocksize Ta property
3199 .It volsize Ta property
3200 .It vscan Ta property
3201 .It xattr Ta property
3207 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
3209 .Ar filesystem Ns | Ns Ar volume
3212 Sets "create time" permissions. These permissions are granted (locally) to the
3213 creator of any newly-created descendent file system.
3219 .Ar perm Ns | Ns Ar @setname Ns Op Ns , Ns Ar perm Ns | Ns Ar @setname Ns
3221 .Ar filesystem Ns | Ns Ar volume
3224 Defines or adds permissions to a permission set. The set can be used by other
3226 commands for the specified file system and its descendents. Sets are evaluated
3227 dynamically, so changes to a set are immediately reflected. Permission sets
3228 follow the same naming restrictions as ZFS file systems, but the name must
3229 begin with an "at sign"
3231 and can be no more than 64 characters long.
3236 .Ar user Ns | Ns Ar group Ns Oo Ns , Ns Ar user Ns | Ns Ar group Oc Ns ...
3237 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
3239 .Ar filesystem Ns | Ns Ar volume
3245 .Fl e Ns | Ns Cm everyone
3246 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
3248 .Ar filesystem Ns | Ns Ar volume
3255 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
3257 .Ar filesystem Ns | Ns Ar volume
3260 Removes permissions that were granted with the
3262 command. No permissions are explicitly denied, so other permissions granted are
3263 still in effect. For example, if the permission is granted by an ancestor. If
3264 no permissions are specified, then all permissions for the specified
3265 .Ar user , group , No or everyone
3266 are removed. Specifying
3268 .Po or using the Fl e
3270 .Pc only removes the permissions that were granted to everyone ,
3271 not all permissions for every user and group. See the
3273 command for a description of the
3276 .Bl -tag -width indent
3278 Recursively remove the permissions from this file system and all descendents.
3286 .Oo Ar perm Ns | Ns Ar @setname Ns Op , Ns Ar perm Ns | Ns Ar @setname Ns
3288 .Ar filesystem Ns | Ns Ar volume
3291 Removes permissions from a permission set. If no permissions are specified,
3292 then all permissions are removed, thus removing the set entirely.
3297 .Ar tag snapshot Ns ...
3300 Adds a single reference, named with the
3302 argument, to the specified snapshot or snapshots. Each snapshot has its own tag
3303 namespace, and tags must be unique within that space.
3305 If a hold exists on a snapshot, attempts to destroy that snapshot by using the
3309 .Bl -tag -width indent
3311 Specifies that a hold with the given tag is applied recursively to the
3312 snapshots of all descendent file systems.
3318 .Op Fl r Ns | Ns Fl d Ar depth
3319 .Ar filesystem Ns | Ns Ar volume Ns | Ns Ar snapshot Ns
3323 Lists all existing user references for the given dataset or datasets.
3324 .Bl -tag -width indent
3326 Used for scripting mode. Do not print headers and separate fields by a single
3327 tab instead of arbitrary white space.
3329 Display numbers in parsable (exact) values.
3331 Lists the holds that are set on the descendent snapshots of the named datasets
3332 or snapshots, in addition to listing the holds on the named snapshots, if any.
3334 Recursively display any holds on the named snapshots, or descendent snapshots of
3335 the named datasets or snapshots, limiting the recursion to
3342 .Ar tag snapshot Ns ...
3345 Removes a single reference, named with the
3347 argument, from the specified snapshot or snapshots. The tag must already exist
3349 .Bl -tag -width indent
3351 Recursively releases a hold with the given tag on the snapshots of all
3352 descendent file systems.
3359 .Op Ar snapshot Ns | Ns Ar filesystem
3362 Display the difference between a snapshot of a given filesystem and another
3363 snapshot of that filesystem from a later time or the current contents of the
3364 filesystem. The first column is a character indicating the type of change,
3365 the other columns indicate pathname, new pathname
3366 .Pq in case of rename ,
3367 change in link count, and optionally file type and/or change time.
3369 The types of change are:
3370 .Bl -column -offset 2n indent
3371 .It \&- Ta path was removed
3372 .It \&+ Ta path was added
3373 .It \&M Ta path was modified
3374 .It \&R Ta path was renamed
3376 .Bl -tag -width indent
3378 Display an indication of the type of file, in a manner similar to the
3382 .Bl -column -offset 2n indent
3383 .It \&B Ta block device
3384 .It \&C Ta character device
3385 .It \&F Ta regular file
3386 .It \&/ Ta directory
3387 .It \&@ Ta symbolic link
3389 .It \&> Ta door (not supported on Fx )
3390 .It \&| Ta named pipe (not supported on Fx )
3391 .It \&P Ta event port (not supported on Fx )
3394 Give more parsable tab-separated output, without header lines and without
3397 Display the path's inode change time as the first column of output.
3404 .Op Fl m Ar memory_limit
3411 as a ZFS channel program on
3414 program interface allows ZFS administrative operations to be run
3415 programmatically via a Lua script.
3416 The entire script is executed atomically, with no other administrative
3417 operations taking effect concurrently.
3418 A library of ZFS calls is made available to channel program scripts.
3419 Channel programs may only be run with root privileges.
3421 For full documentation of the ZFS channel program interface, see the manual
3424 .Bl -tag -width indent
3426 Display channel program output in JSON format.
3427 When this flag is specified and standard output is empty -
3428 channel program encountered an error.
3429 The details of such an error will be printed to standard error in plain text.
3431 Executes a read-only channel program, which runs faster.
3432 The program cannot change on-disk state by calling functions from
3433 the zfs.sync submodule.
3434 The program can be used to gather information such as properties and
3435 determining if changes would succeed (zfs.check.*).
3436 Without this flag, all pending changes must be synced to disk before
3437 a channel program can complete.
3439 Execution time limit, in milliseconds.
3440 If a channel program executes for longer than the provided timeout, it will
3441 be stopped and an error will be returned.
3442 The default timeout is 1000 ms, and can be set to a maximum of 10000 ms.
3443 .It Fl m Ar memory-limit
3444 Memory limit, in bytes.
3445 If a channel program attempts to allocate more memory than the given limit,
3446 it will be stopped and an error returned.
3447 The default memory limit is 10 MB, and can be set to a maximum of 100 MB.
3449 All remaining argument strings are passed directly to the channel program as
3453 for more information.
3458 .Ar jailid filesystem
3461 Attaches the specified
3463 to the jail identified by JID
3465 From now on this file system tree can be managed from within a jail if the
3467 property has been set. To use this functionality, the jail needs the
3471 parameters set to 1 and the
3473 parameter set to a value lower than 2.
3477 for more information on managing jails and configuring the parameters above.
3481 .Ar jailid filesystem
3484 Detaches the specified
3486 from the jail identified by JID
3490 The following exit values are returned:
3491 .Bl -tag -offset 2n -width 2n
3493 Successful completion.
3497 Invalid command line options were specified.
3501 .It Sy Example 1 No Creating a Tn ZFS No File System Hierarchy
3503 The following commands create a file system named
3505 and a file system named
3509 is set for the parent file system, and is automatically inherited by the child
3511 .Bd -literal -offset 2n
3512 .Li # Ic zfs create pool/home
3513 .Li # Ic zfs set mountpoint=/home pool/home
3514 .Li # Ic zfs create pool/home/bob
3516 .It Sy Example 2 No Creating a Tn ZFS No Snapshot
3518 The following command creates a snapshot named
3520 This snapshot is mounted on demand in the
3522 directory at the root of the
3525 .Bd -literal -offset 2n
3526 .Li # Ic zfs snapshot pool/home/bob@yesterday
3528 .It Sy Example 3 No Creating and Destroying Multiple Snapshots
3530 The following command creates snapshots named
3534 and all of its descendent file systems. Each snapshot is mounted on demand in
3537 directory at the root of its file system. The second command destroys the newly
3539 .Bd -literal -offset 2n
3540 .Li # Ic zfs snapshot -r pool/home@yesterday
3541 .Li # Ic zfs destroy -r pool/home@yesterday
3543 .It Sy Example 4 No Disabling and Enabling File System Compression
3545 The following command disables the
3547 property for all file systems under
3549 The next command explicitly enables
3552 .Em pool/home/anne .
3553 .Bd -literal -offset 2n
3554 .Li # Ic zfs set compression=off pool/home
3555 .Li # Ic zfs set compression=on pool/home/anne
3557 .It Sy Example 5 No Listing Tn ZFS No Datasets
3559 The following command lists all active file systems and volumes in the system.
3560 Snapshots are displayed if the
3568 for more information on pool properties.
3569 .Bd -literal -offset 2n
3571 NAME USED AVAIL REFER MOUNTPOINT
3572 pool 450K 457G 18K /pool
3573 pool/home 315K 457G 21K /home
3574 pool/home/anne 18K 457G 18K /home/anne
3575 pool/home/bob 276K 457G 276K /home/bob
3577 .It Sy Example 6 No Setting a Quota on a Tn ZFS No File System
3579 The following command sets a quota of 50 Gbytes for
3581 .Bd -literal -offset 2n
3582 .Li # Ic zfs set quota=50G pool/home/bob
3584 .It Sy Example 7 No Listing Tn ZFS No Properties
3586 The following command lists all properties for
3588 .Bd -literal -offset 2n
3589 .Li # Ic zfs get all pool/home/bob
3590 NAME PROPERTY VALUE SOURCE
3591 pool/home/bob type filesystem -
3592 pool/home/bob creation Tue Jul 21 15:53 2009 -
3593 pool/home/bob used 21K -
3594 pool/home/bob available 20.0G -
3595 pool/home/bob referenced 21K -
3596 pool/home/bob compressratio 1.00x -
3597 pool/home/bob mounted yes -
3598 pool/home/bob quota 20G local
3599 pool/home/bob reservation none default
3600 pool/home/bob recordsize 128K default
3601 pool/home/bob mountpoint /home/bob default
3602 pool/home/bob sharenfs off default
3603 pool/home/bob checksum on default
3604 pool/home/bob compression on local
3605 pool/home/bob atime on default
3606 pool/home/bob devices on default
3607 pool/home/bob exec on default
3608 pool/home/bob filesystem_limit none default
3609 pool/home/bob setuid on default
3610 pool/home/bob readonly off default
3611 pool/home/bob jailed off default
3612 pool/home/bob snapdir hidden default
3613 pool/home/bob snapshot_limit none default
3614 pool/home/bob aclmode discard default
3615 pool/home/bob aclinherit restricted default
3616 pool/home/bob canmount on default
3617 pool/home/bob xattr on default
3618 pool/home/bob copies 1 default
3619 pool/home/bob version 5 -
3620 pool/home/bob utf8only off -
3621 pool/home/bob normalization none -
3622 pool/home/bob casesensitivity sensitive -
3623 pool/home/bob vscan off default
3624 pool/home/bob nbmand off default
3625 pool/home/bob sharesmb off default
3626 pool/home/bob refquota none default
3627 pool/home/bob refreservation none default
3628 pool/home/bob primarycache all default
3629 pool/home/bob secondarycache all default
3630 pool/home/bob usedbysnapshots 0 -
3631 pool/home/bob usedbydataset 21K -
3632 pool/home/bob usedbychildren 0 -
3633 pool/home/bob usedbyrefreservation 0 -
3634 pool/home/bob logbias latency default
3635 pool/home/bob dedup off default
3636 pool/home/bob mlslabel -
3637 pool/home/bob sync standard default
3638 pool/home/bob refcompressratio 1.00x -
3641 The following command gets a single property value.
3642 .Bd -literal -offset 2n
3643 .Li # Ic zfs get -H -o value compression pool/home/bob
3647 The following command lists all properties with local settings for
3649 .Bd -literal -offset 2n
3650 .Li # Ic zfs get -s local -o name,property,value all pool/home/bob
3652 pool/home/bob quota 20G
3653 pool/home/bob compression on
3655 .It Sy Example 8 No Rolling Back a Tn ZFS No File System
3657 The following command reverts the contents of
3659 to the snapshot named
3661 deleting all intermediate snapshots.
3662 .Bd -literal -offset 2n
3663 .Li # Ic zfs rollback -r pool/home/anne@yesterday
3665 .It Sy Example 9 No Creating a Tn ZFS No Clone
3667 The following command creates a writable file system whose initial contents are
3669 .Em pool/home/bob@yesterday .
3670 .Bd -literal -offset 2n
3671 .Li # Ic zfs clone pool/home/bob@yesterday pool/clone
3673 .It Sy Example 10 No Promoting a Tn ZFS No Clone
3675 The following commands illustrate how to test out changes to a file system, and
3676 then replace the original file system with the changed one, using clones, clone
3677 promotion, and renaming:
3678 .Bd -literal -offset 2n
3679 .Li # Ic zfs create pool/project/production
3683 .Pa /pool/project/production
3684 with data and continue with the following commands:
3685 .Bd -literal -offset 2n
3686 .Li # Ic zfs snapshot pool/project/production@today
3687 .Li # Ic zfs clone pool/project/production@today pool/project/beta
3691 .Pa /pool/project/beta
3692 and continue with the following commands:
3693 .Bd -literal -offset 2n
3694 .Li # Ic zfs promote pool/project/beta
3695 .Li # Ic zfs rename pool/project/production pool/project/legacy
3696 .Li # Ic zfs rename pool/project/beta pool/project/production
3699 Once the legacy version is no longer needed, it can be destroyed.
3700 .Bd -literal -offset 2n
3701 .Li # Ic zfs destroy pool/project/legacy
3703 .It Sy Example 11 No Inheriting Tn ZFS No Properties
3705 The following command causes
3711 property from their parent.
3712 .Bd -literal -offset 2n
3713 .Li # Ic zfs inherit checksum pool/home/bob pool/home/anne
3715 .It Sy Example 12 No Remotely Replicating Tn ZFS No Data
3717 The following commands send a full stream and then an incremental stream to a
3718 remote machine, restoring them into
3719 .Sy poolB/received/fs@a
3721 .Sy poolB/received/fs@b ,
3724 must contain the file system
3725 .Sy poolB/received ,
3726 and must not initially contain
3727 .Sy poolB/received/fs .
3728 .Bd -literal -offset 2n
3729 .Li # Ic zfs send pool/fs@a | ssh host zfs receive poolB/received/fs@a
3730 .Li # Ic zfs send -i a pool/fs@b | ssh host zfs receive poolB/received/fs
3739 The following command sends a full stream of
3740 .Sy poolA/fsA/fsB@snap
3741 to a remote machine, receiving it into
3742 .Sy poolB/received/fsA/fsB@snap .
3745 portion of the received snapshot's name is determined from the name of the sent
3748 must contain the file system
3749 .Sy poolB/received .
3751 .Sy poolB/received/fsA
3752 does not exist, it is created as an empty file system.
3753 .Bd -literal -offset 2n
3754 .Li # Ic zfs send poolA/fsA/fsB@snap | ssh host zfs receive -d poolB/received
3756 .It Sy Example 14 No Setting User Properties
3758 The following example sets the user-defined
3759 .Sy com.example:department
3760 property for a dataset.
3761 .Bd -literal -offset 2n
3762 .Li # Ic zfs set com.example:department=12345 tank/accounting
3764 .It Sy Example 15 No Performing a Rolling Snapshot
3766 The following example shows how to maintain a history of snapshots with a
3767 consistent naming scheme. To keep a week's worth of snapshots, the user
3768 destroys the oldest snapshot, renames the remaining snapshots, and then creates
3769 a new snapshot, as follows:
3770 .Bd -literal -offset 2n
3771 .Li # Ic zfs destroy -r pool/users@7daysago
3772 .Li # Ic zfs rename -r pool/users@6daysago @7daysago
3773 .Li # Ic zfs rename -r pool/users@5daysago @6daysago
3774 .Li # Ic zfs rename -r pool/users@4daysago @5daysago
3775 .Li # Ic zfs rename -r pool/users@3daysago @4daysago
3776 .Li # Ic zfs rename -r pool/users@2daysago @3daysago
3777 .Li # Ic zfs rename -r pool/users@yesterday @2daysago
3778 .Li # Ic zfs rename -r pool/users@today @yesterday
3779 .Li # Ic zfs snapshot -r pool/users@today
3785 Property Options on a ZFS File System
3788 The following command shows how to set
3790 property options to enable root access for a specific network on the
3792 file system. The contents of the
3797 .Bd -literal -offset 2n
3798 .Li # Ic zfs set sharenfs="maproot=root,network 192.168.0.0/24" tank/home
3801 Another way to write this command with the same result is:
3802 .Bd -literal -offset 2n
3803 .Li # Ic set zfs sharenfs="-maproot=root -network 192.168.0.0/24" tank/home
3809 Administration Permissions on a
3814 The following example shows how to set permissions so that user
3816 can create, destroy, mount, and take snapshots on
3821 .Bd -literal -offset 2n
3822 .Li # Ic zfs allow cindys create,destroy,mount,snapshot tank/cindys
3823 .Li # Ic zfs allow tank/cindys
3824 ---- Permissions on tank/cindys --------------------------------------
3825 Local+Descendent permissions:
3826 user cindys create,destroy,mount,snapshot
3828 .It Sy Example 18 No Delegating Create Time Permissions on a Tn ZFS No Dataset
3830 The following example shows how to grant anyone in the group
3832 to create file systems in
3834 This syntax also allows staff members to destroy their own file systems, but
3835 not destroy anyone else's file system. The permissions on
3838 .Bd -literal -offset 2n
3839 .Li # Ic zfs allow staff create,mount tank/users
3840 .Li # Ic zfs allow -c destroy tank/users
3841 .Li # Ic zfs allow tank/users
3842 ---- Permissions on tank/users ---------------------------------------
3845 Local+Descendent permissions:
3846 group staff create,mount
3850 Defining and Granting a Permission Set on a
3855 The following example shows how to define and grant a permission set on the
3857 file system. The permissions on
3860 .Bd -literal -offset 2n
3861 .Li # Ic zfs allow -s @pset create,destroy,snapshot,mount tank/users
3862 .Li # Ic zfs allow staff @pset tank/users
3863 .Li # Ic zfs allow tank/users
3864 ---- Permissions on tank/users ---------------------------------------
3866 @pset create,destroy,mount,snapshot
3867 Local+Descendent permissions:
3870 .It Sy Example 20 No Delegating Property Permissions on a Tn ZFS No Dataset
3872 The following example shows to grant the ability to set quotas and reservations
3875 file system. The permissions on
3878 .Bd -literal -offset 2n
3879 .Li # Ic zfs allow cindys quota,reservation users/home
3880 .Li # Ic zfs allow users/home
3881 ---- Permissions on users/home ---------------------------------------
3882 Local+Descendent permissions:
3883 user cindys quota,reservation
3884 .Li # Ic su - cindys
3885 .Li cindys% Ic zfs set quota=10G users/home/marks
3886 .Li cindys% Ic zfs get quota users/home/marks
3887 NAME PROPERTY VALUE SOURCE
3888 users/home/marks quota 10G local
3890 .It Sy Example 21 No Removing ZFS Delegated Permissions on a Tn ZFS No Dataset
3892 The following example shows how to remove the snapshot permission from the
3896 file system. The permissions on
3899 .Bd -literal -offset 2n
3900 .Li # Ic zfs unallow staff snapshot tank/users
3901 .Li # Ic zfs allow tank/users
3902 ---- Permissions on tank/users ---------------------------------------
3904 @pset create,destroy,mount,snapshot
3905 Local+Descendent permissions:
3908 .It Sy Example 22 Showing the differences between a snapshot and a ZFS Dataset
3910 The following example shows how to see what has changed between a prior
3911 snapshot of a ZFS Dataset and its current state. The
3913 option is used to indicate type information for the files affected.
3914 .Bd -literal -offset 2n
3915 .Li # Ic zfs diff tank/test@before tank/test
3917 M F /tank/test/linked (+1)
3918 R F /tank/test/oldname -> /tank/test/newname
3919 - F /tank/test/deleted
3920 + F /tank/test/created
3921 M F /tank/test/modified
3935 This manual page is a
3937 reimplementation of the
3941 modified and customized for
3943 and licensed under the
3944 Common Development and Distribution License
3949 implementation of this manual page was initially written by
3950 .An Martin Matuska Aq mm@FreeBSD.org .