Bug#542915: pbuilder: removes data from bind-mounted directories

Matthew Palmer mpalmer at debian.org
Sun Dec 12 03:07:56 UTC 2010


tag 542915 +moreinfo
thanks

Hi Jakub,

I'm trying to reproduce this bug, but I can't manage to get pbuilder to
behave in the manner you describe -- but I can't find any changes to
pbuilder in the meantime that would explain a change in behaviour.

Here is what I did, using pbuilder 0.199:

1) Created a minimal package that failed to build

2) mkdir /tmp/hooks

3) cp /usr/share/pbuilder/examples/C10shell /tmp/hooks

4) pbuilder --build --basetgz ~/chroots/sid.tgz --hookdir /tmp/hooks broken.dsc

5) Wait for build to fail and drop into a shell; switch to another xterm

6) mkdir /tmp/valuable

7) touch /tmp/valuable/do-not-delete-please

8) mount -o bind /tmp/valuable /var/cache/pbuilder/build/XXXXX/home

9) Switch back to the pbuilder xterm; exit out of the shell

Now pbuilder reports a couple of errors:

rmdir: failed to remove `/var/cache/pbuilder/build//XXXXX/home': Device or resource busy
rmdir: failed to remove `/var/cache/pbuilder/build//XXXXX': Directory not empty

But if I ls /tmp/valuable, the file do-not-delete-please is still there.

Would you be able to tell me where my attempt at reproducing the problem
differs from your experience, or let me know if the bug no longer appears in
pbuilder 0.199?

Thanks,
- Matt





More information about the Pbuilder-maint mailing list