]> git.ipfire.org Git - thirdparty/systemd.git/commit
tmpfiles: create subvolumes for "v", "q", and "Q" only if / is a subvolume 1915/head
authorLennart Poettering <lennart@poettering.net>
Mon, 16 Nov 2015 14:25:42 +0000 (15:25 +0100)
committerLennart Poettering <lennart@poettering.net>
Mon, 16 Nov 2015 14:25:42 +0000 (15:25 +0100)
commit2904e949f23aeb17b7e21a2a0f8c43f959a07f98
tree741b948bb870113c5bdd21783cc3948555b609d7
parentab32771aa0c2c2ab70248e7e0a4be92fd73512ad
tmpfiles: create subvolumes for "v", "q", and "Q" only if / is a subvolume

It's not a good idea to create subvolumes for parts of the OS tree (such
as /home, or /var) if the root directory is not a subvolume too. We
shouldn't assume control of "heavier" objects such as subvolumes, if the
originating object (the root directory) is a "light-weight" object, i.e.
a plain directory.

Effectively this means that chroot() environments that are run on a
plain directory do not have to deal with problems around systemd
creating subvolumes that cannot be removed with a simple "rm" anymore.
However, if the chroot manager creates a proper subvolume for such an
environment it will also get further subvolumes placed in there, under
the assumption that the manager understands the concept of subvolumes in
that case.
man/tmpfiles.d.xml
src/basic/btrfs-util.c
src/basic/btrfs-util.h
src/tmpfiles/tmpfiles.c