Bug#542915: pbuilder: removes data from bind-mounted directories
Loïc Minier
lool at dooz.org
Mon Sep 21 13:46:04 UTC 2009
On Fri, Sep 18, 2009, Jakub Wilk wrote:
> First of all, you should not close a bug without a proper explanation.
>
> mount and rm does exactly what they are meant to do (and what is
> documented). This is not true for your package.
>
> In fact, this bug is easily fixable:
> - In most cases, `umount -a` called inside chroot does unmount
> everything that should be unmounted.
> - If it does not (i.e. if /proc/mounts contents changed during a
> build), pbuilder should refrain from rm-Rf-ing the chroot.
It seems pbuilder doesn't rm -r (it uses find -xdev to rm -f all
non-directories and then rmdir on dirs; it could as well use rm
--one-file-system IMO) see clean_subdirectories() in pbuilder-modules;
it also has some logic to check for mounts not having been properly
unmounted (seems_truly_unmounted() in pbuilder-modules). Perhaps
you're hitting another rm such as the hooks one?
--
Loïc Minier
More information about the Pbuilder-maint
mailing list