From eec7fcf965763d5395c336f92cd56b193d054947 Mon Sep 17 00:00:00 2001 From: "Jan Alexander Steffens (heftig)" Date: Tue, 7 Mar 2017 20:14:50 +0100 Subject: archbuild/makechrootpkg: Delete subvolumes in roots The systemd package creates a subvolume at /var/lib/machines (through tmpfiles), if it can. We need to delete this subvolume before we can delete the parent subvolume. Look through the root for inodes with the number 256. These identify subvolume roots. --- archbuild.in | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'archbuild.in') diff --git a/archbuild.in b/archbuild.in index b192788..a78353c 100644 --- a/archbuild.in +++ b/archbuild.in @@ -52,9 +52,7 @@ if ${clean_first} || [[ ! -d "${chroots}/${repo}-${arch}" ]]; then lock 9 "$copy.lock" "Locking chroot copy '$copy'" - if is_btrfs "${copy}"; then - { type -P btrfs && btrfs subvolume delete "${copy}"; } &>/dev/null - fi + subvolume_delete_recursive "${copy}" rm -rf --one-file-system "${copy}" done exec 9>&- -- cgit v1.2.3-70-g09d2