Re:TFS: A file system built for performance, space efficienc...
by notacoward on Sunday May 21, 2017 @08:08AM
(#14386913)
A power-off is a simple fault, with fairly well-defined effects. It's actually one of the easiest cases for a data-storage system to deal with. "Hardware failure" includes all manner of crazy Byzantine faults, many of which are literally impossible to deal with. What this is saying is that TFS's model of the underlying hardware is that it will either execute all writes correctly or stop executing any.
Sadly, a lot of hardware has much more complicated behavior than that. A lot of RAID cards in particular will lie about what was actually written, so in a power-off scenario later writes might have made it while earlier ones didn't, writes can be incomplete, etc. I don't mean this as a knock against TFS. It's more of a suggestion that the fault model be expanded to include at least a few more possibilities.
Re:TFS: A file system built for performance, space efficienc...
by gpm on Sunday May 21, 2017 @08:05AM
(#14386903)
I think the spec answers your question here
TFS provides following guarantees:
- Unless data corruption happens, the disk should never be
an inconsistent state \footnote{TFS achieves this without using
journaling or a transactional model.}. Poweroff and the alike
should not affect the system such that it enters an invalid or
inconsistent state.
Provided that following premises hold:
- Any sector (assumed to be a power of two of at least
\minimumsectorsize bytes) can be read and written atomically,
i.e. it is never partially written, and interrupting the write
will never render the disk in a state in which it not already
is written or retaining the old data.
Data corruption can break these guarantees or premises, and TFS
encompasses certain measures against such corruption, but they are
strictly speaking heuristic, like any error detection and correction
method, as the damage could be across all the disks.
Re:TFS: A file system built for performance, space efficienc...
by jstimpfle on Sunday May 21, 2017 @07:48AM
(#14386854)
The section "2. Hardware Assumptions" in the Sqlite docs here has some interesting related stuff: https://www.sqlite.org/atomiccommit.html
Re:TFS: A file system built for performance, space efficienc...
by nbevans on Sunday May 21, 2017 @06:59AM
(#14386694)
Hardware failures could imply "flipped bits" (depending on failure mode) whereas loss of power should just mean "truncated bits".
Re:TFS: A file system built for performance, space efficienc...
by zitterbewegung on Sunday May 21, 2017 @07:38AM
(#14386817)
Unexpected shutdown would just use the features of a Journaling file system to recover the data. A hardware failure would be a Raid controller failure or malfunction or a hard drive / SSD failure .
What is the difference here between a hardware failure and a unexpected power failure?