Re: [patch] ext2/3: document conditions when reliable operation is possible

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Florian Weimer
Date: Tuesday, August 25, 2009 - 7:43 am

* Theodore Tso:


Hmm.  What does "not being able to handle failed writes" actually
mean?  AFAICS, there are two possible answers: "all bets are off", or
"we'll tell you about the problem, and all bets are off".


Right.  And a lot of database systems make the same assumption.
Oracle Berkeley DB cannot deal with partial page writes at all, and
PostgreSQL assumes that it's safe to flip a few bits in a sector
without proper WAL (it doesn't care if the changes actually hit the
disk, but the write shouldn't make the sector unreadable or put random
bytes there).


The DMA transaction should fail due to ECC errors, though.


I think the general idea is to protect valuable data with WAL.  You
overwrite pages on disk only after you've made a backup copy into WAL.
After a power loss event, you replay the log and overwrite all garbage
that might be there.  For the WAL, you rely on checksum and sequence
numbers.  This still doesn't help against write failures where the
system continues running (because the fsync() during checkpointing
isn't guaranteed to report errors), but it should deal with the power
failure case.  But this assumes that the file system protects its own
data structure in a similar way.  Is this really too much to demand?

Partial failures are extremely difficult to deal with because of their
asynchronous nature.  I've come to accept that, but it's still
disappointing.

-- 
Florian Weimer                <fweimer@bfk.de>
BFK edv-consulting GmbH       http://www.bfk.de/
Kriegsstraße 100              tel: +49-721-96201-1
D-76133 Karlsruhe             fax: +49-721-96201-99
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: ext2/3: document conditions when reliable operation is ..., Goswin von Brederlow, (Mon Mar 30, 8:06 am)
Re: [patch] ext2/3: document conditions when reliable oper ..., Florian Weimer, (Tue Aug 25, 7:43 am)
[patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 3:21 pm)
[patch] document that ext2 can't handle barriers, Pavel Machek, (Tue Aug 25, 3:27 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 3:33 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 3:40 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 3:59 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 4:37 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 4:48 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 4:56 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:06 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:12 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 5:12 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 5:20 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:20 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 5:26 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 5:26 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 5:28 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:38 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:39 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Tue Aug 25, 5:44 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 5:45 pm)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Tue Aug 25, 5:50 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 6:17 pm)
Re: [patch] document flash/RAID dangers, david, (Tue Aug 25, 6:19 pm)
Re: [patch] ext2/3: document conditions when reliable oper ..., Henrique de Moraes H ..., (Tue Aug 25, 7:53 pm)
Re: [patch] document flash/RAID dangers, Rik van Riel, (Tue Aug 25, 9:20 pm)
Re: [patch] document flash/RAID dangers, Rik van Riel, (Tue Aug 25, 9:24 pm)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Wed Aug 26, 4:21 am)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Wed Aug 26, 4:22 am)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Wed Aug 26, 4:25 am)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Wed Aug 26, 4:58 am)
Re: [patch] document flash/RAID dangers, Theodore Tso, (Wed Aug 26, 5:37 am)
Re: [patch] document flash/RAID dangers, Theodore Tso, (Wed Aug 26, 5:40 am)
Re: [patch] document flash/RAID dangers, Ric Wheeler, (Wed Aug 26, 6:11 am)
Re: [patch] document flash/RAID dangers, david, (Wed Aug 26, 6:44 am)
Re: [patch] document flash/RAID dangers, Rik van Riel, (Wed Aug 26, 7:45 am)
Re: MD/DM and barriers (was Re: [patch] ext2/3: document c ..., Alasdair G Kergon, (Thu Aug 27, 11:09 am)
Re: raid is dangerous but that's secret, Florian Weimer, (Fri Aug 28, 12:11 am)
Re: raid is dangerous but that's secret, NeilBrown, (Fri Aug 28, 12:23 am)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Sat Aug 29, 2:38 am)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Sat Aug 29, 2:39 am)
Re: [patch] document flash/RAID dangers, Ron Johnson, (Sat Aug 29, 4:47 am)
Re: [patch] document flash/RAID dangers, jim owens, (Sat Aug 29, 9:12 am)
Re: [patch] document flash/RAID dangers, Pavel Machek, (Sat Aug 29, 11:49 pm)
Re: raid is dangerous but that's secret (was Re: [patch] e ..., Christoph Hellwig, (Sun Aug 30, 9:35 am)
Re: raid is dangerous but that's secret (was Re: [patch] e ..., Christoph Hellwig, (Mon Aug 31, 6:16 am)
Re: raid is dangerous but that's secret (was Re: [patch] e ..., Christoph Hellwig, (Mon Aug 31, 6:21 am)
Re: raid is dangerous but that's secret (was Re: [patch] e ..., Jesse Brandeburg, (Mon Aug 31, 10:49 am)
Re: raid is dangerous but that's secret (was Re: [patch] e ..., Christoph Hellwig, (Mon Aug 31, 11:31 am)