2021-12-27 01:14:29 +00:00
|
|
|
# btrfs property
|
|
|
|
|
2024-02-14 20:25:13 +00:00
|
|
|
> Get, set, or list properties for a BTRFS filesystem object (files, directories, subvolumes, filesystems, or devices).
|
2022-11-15 11:50:15 +00:00
|
|
|
> More information: <https://btrfs.readthedocs.io/en/latest/btrfs-property.html>.
|
2021-12-27 01:14:29 +00:00
|
|
|
|
|
|
|
- List available properties (and descriptions) for the given btrfs object:
|
|
|
|
|
|
|
|
`sudo btrfs property list {{path/to/btrfs_object}}`
|
|
|
|
|
|
|
|
- Get all properties for the given btrfs object:
|
|
|
|
|
|
|
|
`sudo btrfs property get {{path/to/btrfs_object}}`
|
|
|
|
|
|
|
|
- Get the `label` property for the given btrfs filesystem or device:
|
|
|
|
|
|
|
|
`sudo btrfs property get {{path/to/btrfs_filesystem}} label`
|
|
|
|
|
|
|
|
- Get all object type-specific properties for the given btrfs filesystem or device:
|
|
|
|
|
|
|
|
`sudo btrfs property get -t {{subvol|filesystem|inode|device}} {{path/to/btrfs_filesystem}}`
|
|
|
|
|
|
|
|
- Set the `compression` property for a given btrfs inode (either a file or directory):
|
|
|
|
|
|
|
|
`sudo btrfs property set {{path/to/btrfs_inode}} compression {{zstd|zlib|lzo|none}}`
|