1BTRFS-PROPERTY(8) BTRFS BTRFS-PROPERTY(8)
2
3
4
6 btrfs-property - get/set/list properties for given filesystem object
7
9 btrfs property <subcommand> <args>
10
12 btrfs property is used to get/set/list property for given filesystem
13 object. The object can be an inode (file or directory), subvolume or
14 the whole filesystem. See the description of get subcommand for more
15 information about both btrfs object and property.
16
17 *btrfs property provides an unified and user-friendly method to tune
18 different btrfs properties instead of using the traditional method like
19 chattr(1) or lsattr(1).
20
22 get [-t <type>] <object> [<name>]
23 get property from a btrfs object of given type
24
25 A btrfs object, which is set by object, can be a btrfs filesys‐
26 tem itself, a btrfs subvolume, an inode (file or directory) in‐
27 side btrfs, or a device on which a btrfs exists.
28
29 The option -t can be used to explicitly specify what type of ob‐
30 ject you meant. This is only needed when a property could be set
31 for more then one object type.
32
33 Possible types are s[ubvol], f[ilesystem], i[node] and d[evice],
34 where the first lettes is a shortcut.
35
36 Set the name of property by name. If no name is specified, all
37 properties for the given object are printed. name is one of the
38 following:
39
40 ro read-only flag of subvolume: true or false. Please also
41 see section SUBVOLUME FLAGS in btrfs-subvolume(8) for
42 possible implications regarding incremental send.
43
44 label label of the filesystem. For an unmounted filesystem,
45 provide a path to a block device as object. For a mounted
46 filesystem, specify a mount point.
47
48 compression
49 compression algorithm set for an inode, possible values:
50 lzo, zlib, zstd. To disable compression use no or none.
51 Empty value resets the property and sets a default value.
52 .. note:
53
54 This has changed in version 5.18 of btrfs-progs and
55 requires kernel 5.14 or newer to work.
56
57 list [-t <type>] <object>
58 Lists available properties with their descriptions for the given
59 object.
60
61 See the description of get subcommand for the meaning of each
62 option.
63
64 set [-f] [-t <type>] <object> <name> <value>
65 Sets a property on a btrfs object.
66
67 See the description of get subcommand for the meaning of each
68 option.
69
70 Options
71
72 -f Force the change. Changing some properties may involve
73 safety checks or additional changes that depend on the
74 properties semantics.
75
77 btrfs property returns a zero exit status if it succeeds. Non zero is
78 returned in case of failure.
79
81 btrfs is part of btrfs-progs. Please refer to the btrfs wiki
82 http://btrfs.wiki.kernel.org for further details.
83
85 mkfs.btrfs(8), lsattr(1), chattr(1)
86
88 2022
89
90
91
92
935.18 May 25, 2022 BTRFS-PROPERTY(8)