On Sun, 04 Oct 2009 18:25:14 +0200
Rodolphe Rocca <[email protected]> wrote:
> I understand that in case of a machine crashing, a package gets
> partially installed, as long as the package files content is either
> the old one or the new one. This can potentially cause trouble, but
> has a higher resilience than ending with some empty files in VDB
> causing paludis to be unusable until a manual intervention
> in /var/cache/db.

No, it can also result in partially written new files being installed.

> I tried to turn the auto_da_alloc ext4 mount option on as it is
> supposed to fix the "zero file length" issue for some file replacing
> patterns. A few minutes later I got a new crash and empty files
> again. So I guess the corruption is unrelated or paludis uses a
> rename pattern which is not detected by ext4.

The problem is not a rename pattern, and it has nothing to do with
allocation. It's quite simple: if you don't cleanly unmount a
filesystem, or if you don't cleanly power off your computer after
unmounting a filesystem, things will break.

Where Paludis does renames for merging, it does so to prevent a
partially written executable from existing. If anyone tried to launch
an executable when it was partially written, weird things would happen;
using a rename removes that case, although there is a small amount of
time between when the old executable is removed and the new one is
renamed into place. Handling unclean unmounts is not a consideration.

> Now I'm at the point where I disabled ext4 delayed allocation
> (nodelalloc mount option). Let's see what happens.

Things will still break if you randomly power off your computer. The
only difference is that the breakage may display itself slightly
differently. You can still end up with partially written or empty
files; you may just not notice them as frequently.

-- 
Ciaran McCreesh

Attachment: signature.asc
Description: PGP signature

_______________________________________________
paludis-user mailing list
[email protected]
http://lists.pioto.org/mailman/listinfo/paludis-user

Reply via email to