[systemd-devel] [PATCH] tmpfiles: don't create subvolumes in chroot
"Jóhann B. Guðmundsson"
johannbg at gmail.com
Wed Apr 1 05:40:29 PDT 2015
On 04/01/2015 12:33 PM, Jan Synacek wrote:
> ---
> src/tmpfiles/tmpfiles.c | 8 +++++++-
> 1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/src/tmpfiles/tmpfiles.c b/src/tmpfiles/tmpfiles.c
> index 494fd1a..9280fd7 100644
> --- a/src/tmpfiles/tmpfiles.c
> +++ b/src/tmpfiles/tmpfiles.c
> @@ -1099,9 +1099,15 @@ static int create_item(Item *i) {
>
> break;
>
> + case CREATE_SUBVOLUME:
> +
> + /* Don't create subvolumes in chrooted environments. */
> + if (running_in_chroot())
> + break;
> + /* FALLTHROUGH */
> +
> case CREATE_DIRECTORY:
> case TRUNCATE_DIRECTORY:
> - case CREATE_SUBVOLUME:
>
> RUN_WITH_UMASK(0000)
> mkdir_parents_label(i->path, 0755);
This breakage is not limited to chroot, subvolumes should not be created
et all.
Just file a patch that replace v for d for the /var/lib/machines entry
in /usr/lib/tmpfiles.d/var.conf which you are undoubtedly trying to fix
here since it breaks among other things mock.
JBG
More information about the systemd-devel
mailing list