Forrest logo
back to the zfs tool

zfs:tldr:9129f

zfs: Enable compression on a filesystem.
$ zfs set compression=on ${pool_name-filesystem_name}
try on your machine

This command is used to enable compression on a ZFS pool or file system. Here's a breakdown of each component: - zfs set: This is the command to modify or set properties for ZFS pools and file systems.

  • compression=on: This specifies the property to be modified. In this case, we are setting the compression property to "on", which means that compression will be enabled for the specified pool or file system.
  • ${pool_name-filesystem_name}: This is a placeholder for the name of the ZFS pool or file system you want to enable compression on. You need to replace ${pool_name-filesystem_name} with the actual name of the pool or file system you want to modify. For example, if you want to enable compression on a ZFS pool named "my_pool", the command would look like this: zfs set compression=on my_pool Or if you want to enable compression on a ZFS file system named "my_filesystem" within the "my_pool" pool, the command would be: zfs set compression=on my_pool/my_filesystem
This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the zfs tool