Re: soft update vs journaling?

From: James Courtier-Dutton
Date: Sun Jan 22 2006 - 14:25:15 EST


John Richard Moser wrote:

Unfortunately, journaling uses a chunk of space. Imagine a journal on a
USB flash stick of 128M; a typical ReiserFS journal is 32 megabytes!
Sure it could be done in 8 or 4 or so; or (in one of my file system
designs) a static 16KiB block could reference dynamicly allocated
journal space, allowing the system to sacrifice performance and shrink
the journal when more space is needed. Either way, slow media like
floppies will suffer, HARD; and flash devices will see a lot of
write/erase all over the journal area, causing wear on that spot.


My understanding is that if one designed a power supply with enough headroom, one could remove the power and still have time to write dirty sectors to the USB flash stick. Would this not remove the need for a journaling fs on a flash stick. This would remove the "wear on that spot" problem. Actually USB flash sticks are a bit clever, in that they add an extra layer of translation to the write. I.e. If you write to the same sector again and again, the USB flash stick will actually write it to a different area of the memory each time. This is specifically done to save the "wear on that spot" problem.

This "flush on power fail" approach is not so easy with a HD because it uses more power and takes longer to flush.

James

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/