Re: [PATCH 1/3] dm: log writes target

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

 



On 03/23/2015 02:02 PM, Vivek Goyal wrote:
On Thu, Mar 19, 2015 at 04:31:08PM -0400, Josef Bacik wrote:

[..]
+ * We log writes only after they have been flushed, this makes the log describe
+ * close to the order in which the data hits the actual disk, not its cache.  So
+ * for example the following sequence (W means write, C means complete)
+ *
+ * Wa,Wb,Wc,Cc,Ca,FLUSH,FUAd,Cb,CFLUSH,CFUAd
+ *
+ * Would result in the log looking like this
+ *
+ * c,a,flush,fuad,b,<other writes>,<next flush>
+ *

A minor nit, Should this sequence be following.

c,a,b, flush,fuad,<other writes>,<next flush>

when flush completed by that time write of b has completed too. So it
should be written first?


So we want to catch file systems behaving badly by not waiting for the IO they care about to complete before issuing their flush, so we take the super pessimistic view that only IO that has completed by FLUSH issue time can truly be safe. For all we know the flush could have happened first and we just happen to get the endio called for b first instead of the flush, so to make it mostly likely that we catch fs bugs we enforce this idea that only completed IO can be sure to have been flushed at flush submit time. Thanks,

Josef

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel




[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux