ZFS: How to enable cache and logs.

Šimun Mikecin numisemis at gmail.com
Thu May 12 08:45:05 UTC 2011


On 12. svi. 2011., at 10:34, Jeremy Chadwick wrote:
> 
> I had no idea the primary point of a SLOG was to deal with applications
> that make use of O_SYNC.  I thought it was supposed to improve write
> performance for both asynchronous and synchronous writes.  Obviously I'm
> wrong here.

If the application is not using O_SYNC, write operation returns to the app before the data is actually written.

> What guarantee is there that the intent log -- which is written to the
> disk -- actually got written to the disk in the middle of a power
> failure?  There's a lot of focus there on the idea that "the intent log
> will fix everything, but may lose writes", but what guarantee do I have
> that the intent log isn't corrupt or botched during a power failure?

I expect that checksumming also works for ZIL (anybody knows?). If that is the case, corruption would be detected, but you will have lost data unless you are using mirrored slog devices.



More information about the freebsd-fs mailing list