[linux-lvm] fsync() and LVM

Les Mikesell lesmikesell at gmail.com
Tue Mar 17 18:17:02 UTC 2009


Stuart D. Gathman wrote:
> On Tue, 17 Mar 2009, Marco Colombo wrote:
> 
>> It seems to me that in my setup, disabling the caches on the disks does
>> bring data to the platters, and that noone is "lying" about fsync.
>>
>> Now I'm _really_ confused.
> 
> That's been my claim all along - that the broken fsync only affects
> on disk cache.  LVM itself does not reorder writes in any way - it just
> fails to pass along the write barrier.  fsync() does *start* writing
> the dirty buffers (implemented in the fs code).  It just doesn't 
> wait for the writes to finish getting to the platters.  Apparently,
> it does wait for the write to get to the drive (but I'm not certain).

Given that fsync() is supposed to return the status of the completion of 
the physical write, that sounds broken to me.  Do the LVM's in question 
here have more than one underlying device, and does it matter?

-- 
   Les Mikesell
    lesmikesell at gmail.com




More information about the linux-lvm mailing list