Bug#588339: sync/fsync in dpkg

2010-10-26 Thread Chanoch (Ken) Bloom
On Tue, 2010-10-26 at 10:36 +0200, Sven Joachim wrote: > On 2010-10-21 19:14 +0200, Jonathan Nieder wrote: > > > Ken Bloom wrote: > > > >> And what mount options are you using? If you're using > >> defaults, /etc/mtab (and therefore the mount command) won't know what > >> the default values are, b

Bug#588339: sync/fsync in dpkg

2010-10-26 Thread Sven Joachim
On 2010-10-21 19:14 +0200, Jonathan Nieder wrote: > Ken Bloom wrote: > >> And what mount options are you using? If you're using >> defaults, /etc/mtab (and therefore the mount command) won't know what >> the default values are, but you can check /proc/mounts which will >> include the data= mount o

Bug#588339: sync/fsync in dpkg

2010-10-22 Thread Guillem Jover
Hi! On Wed, 2010-10-20 at 16:11:05 -0500, Chanoch (Ken) Bloom wrote: > > 1. On ext4 with certain mount options, using rename() without first > >calling fsync() to get the data on disk has an unfortunate risk of > >clearing out a file[1]. > > This issue was current at the beginning of 2010

Bug#588339: sync/fsync in dpkg

2010-10-21 Thread Jonathan Nieder
(+cc: debian-kernel) Ken Bloom wrote: > And what mount options are you using? If you're using > defaults, /etc/mtab (and therefore the mount command) won't know what > the default values are, but you can check /proc/mounts which will > include the data= mount option. data=ordered. That's the de

Bug#588339: sync/fsync in dpkg

2010-10-21 Thread Ken Bloom
On Thu, 2010-10-21 at 18:36 +0200, Sven Joachim wrote: > On 2010-10-21 02:05 +0200, Chanoch (Ken) Bloom wrote: > > > The version you're using in Bug #588254 is the first version of dpkg() > > that uses sync(). What I'd like to establish is whether Linus and > > friends have fixed fsync() so that i

Bug#588339: sync/fsync in dpkg

2010-10-21 Thread Sven Joachim
On 2010-10-21 02:05 +0200, Chanoch (Ken) Bloom wrote: > The version you're using in Bug #588254 is the first version of dpkg() > that uses sync(). What I'd like to establish is whether Linus and > friends have fixed fsync() so that it's significantly faster than > sync(). It sounded like that was

Bug#588339: sync/fsync in dpkg

2010-10-20 Thread Chanoch (Ken) Bloom
On Thu, 2010-10-21 at 01:04 +0300, Modestas Vainius wrote: > Hello, > > On ketvirtadienis 21 Spalis 2010 00:11:05 Chanoch (Ken) Bloom wrote: > > This issue was current at the beginning of 2010, around the time Bug > > #567089 was filed and discussed. It's been fixed in the kernel since > > then. S

Bug#588339: sync/fsync in dpkg

2010-10-20 Thread Modestas Vainius
Hello, On ketvirtadienis 21 Spalis 2010 00:11:05 Chanoch (Ken) Bloom wrote: > This issue was current at the beginning of 2010, around the time Bug > #567089 was filed and discussed. It's been fixed in the kernel since > then. See http://lwn.net/Articles/322823/, and > http://lwn.net/Articles/32647

Bug#588339: sync/fsync in dpkg

2010-10-20 Thread Chanoch (Ken) Bloom
> Why would sync() do anything on tmpfs? The s_bdi field from its > superblock is never set to non-NULL in mm/shmem.c, so that’s not it. > Ah, but sync_filesystems() iterates over all filesystems, not just > those accessible from the chroot. > > This sucks. To recap: > > 1. On ext4 with certain