|ZPOOL-CREATE(8)||System Manager's Manual||ZPOOL-CREATE(8)|
create ZFS storage pool
] pool vdev…
labelclear, do not refer to the same device. Using the same device in two pools will result in pool corruption. There are some uses, such as being currently mounted, or specified as the dedicated dump device, that prevents a device from ever being used by ZFS. Other uses, such as having a preexisting UFS file system, can be overridden with
-f. The command also checks that the replication strategy for the pool is consistent. An attempt to combine redundant and non-redundant storage in a single pool, or to mix disks and files, results in an error unless
-fis specified. The use of differently-sized devices within a single raidz or mirror group is also flagged as an error unless
-fis specified. Unless the
-Roption is specified, the default mount point is /pool. The mount point must not exist or must be empty, or else the root dataset will not be able to be be mounted. This can be overridden with the
-moption. By default all supported features are enabled on the new pool. The
-doption and the
-ocompatibility property (e.g
-ocompatibility=2020) can be used to restrict the features that are enabled, so that the pool can be imported on other releases of ZFS.
- Do not enable any features on the new pool. Individual features can be
enabled by setting their corresponding properties to
-o. See zpool-features(7) for details about feature properties.
- Forces use of vdevs, even if they appear in use or specify a conflicting replication level. Not all devices can be overridden in this manner.
- Sets the mount point for the root dataset. The default mount point is /pool or altroot/pool if altroot is specified. The mount point must be an absolute path, legacy, or none. For more information on dataset mount points, see zfsprops(7).
- Displays the configuration that would be used without actually creating the pool. The actual pool creation can still fail due to insufficient privileges or device sharing.
- Sets the given pool properties. See zpoolprops(7) for a list of valid properties that can be set.
- Specifies compatibility feature sets. See zpool-features(7) for more information about compatibility feature sets.
- Sets the given pool feature. See the zpool-features(7) section for a list of valid features that can be set. Value can be either disabled or enabled.
- Sets the given file system properties in the root file system of the pool. See zfsprops(7) for a list of valid properties that can be set.
- Equivalent to
- Sets the in-core pool name to tname while the on-disk name will be the name specified as pool. This will set the default of the cachefile property to none. This is intended to handle name space collisions when creating pools for other systems, such as virtual machines or physical machines whose pools live on network block devices.
Example 1: Creating a RAID-Z Storage PoolThe following command creates a pool with a single raidz root vdev that consists of six disks:
createtank raidz sda sdb sdc sdd sde sdf
Example 2: Creating a Mirrored Storage PoolThe following command creates a pool with two mirrors, where each mirror contains two disks:
createtank mirror sda sdb mirror sdc sdd
Example 3: Creating a ZFS Storage Pool by Using PartitionsThe following command creates a non-redundant pool using two disk partitions:
createtank sda1 sdb2
Example 4: Creating a ZFS Storage Pool by Using FilesThe following command creates a non-redundant pool using files. While not recommended, a pool based on files can be useful for experimental purposes.
createtank /path/to/file/a /path/to/file/b
Example 5: Managing Hot SparesThe following command creates a new pool with an available hot spare:
createtank mirror sda sdb spare sdc
Example 6: Creating a ZFS Pool with Mirrored Separate Intent LogsThe following command creates a ZFS storage pool consisting of two, two-way mirrors and mirrored log devices:
zpool-destroy(8), zpool-export(8), zpool-import(8)
createpool mirror sda sdb mirror sdc sdd log mirror sde sdf
|March 16, 2022||Debian|