[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Pre-approval request for dpkg sync() changes for squeeze



Hi!

On Mon, 2010-11-15 at 19:31:00 +0100, Philipp Kern wrote:
> On Mon, Nov 15, 2010 at 09:58:47AM +0100, Sven Joachim wrote:
> > All this is with a standard squeeze kernel on an otherwise idle system.
> > It should be noted that with lots of other disk activity such as writing
> > to USB disks, the figures in dpkg 1.15.8.5 can become much worse and
> > dpkg might even stall because of the many sync() calls:
> > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=595927.
> > 
> > As far as ext4 is concerned, switching back to fsync() seems to be
> > acceptable only if the filesystem is mounted with the nodelalloc
> > option.  Maybe the installer should set this up.
> 
> and I don't suppose we could make that the default?

That would be the sanest thing to do IMO, otherwise the users might
lose data in general. Barring that probably d-i could set the flag
on newly created file systems. And otherwise as a last resort an entry
on the release notes warning users of the perils of using ext4 with
default options (in addition to the really bad performance with
applications using fsync()) would be nice.

> Is there anything else the dpkg developers can try to be portable
> and still not be sacrificing performance?

It's not much about portability than the side-effects using sync()
entails, as can be seen by the bug report Sven pointed out to. Which
I consider unacceptable for an application to get into. The portability
issues are just a symptom of the wrongness of using sync() as a
subsitute for fsync().

regards,
guillem


Reply to: