All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sandeen <sandeen@redhat.com>
To: Andrey Sidorov <qrxd43@motorola.com>
Cc: dedekind1@gmail.com, "Ohlsson, Fredrik (GE Healthcare,
	consultant)" <Fredrik.Ohlsson@ge.com>,
	linux-ext4@vger.kernel.org
Subject: Re: ext4 settings in an embedded system
Date: Fri, 16 Nov 2012 09:40:13 -0600	[thread overview]
Message-ID: <50A65E5D.7040305@redhat.com> (raw)
In-Reply-To: <CAA0+VHyODd+hsSL6FBqcLGb_r3ViHmL78ay=8k5CJeP0=Z2k7A@mail.gmail.com>

On 11/15/12 4:01 AM, Andrey Sidorov wrote:
> On Thu, Nov 15, 2012 at 12:42 PM, Artem Bityutskiy <dedekind1@gmail.com> wrote:
> 
>> We conducted some 3 years ago. Results were quite good for ext4 - in
>> many cases it could recover without a need to run ckfs.ext4, sometimes
>> it was not mountable, but ckfs.ext4 helped.
>>
>> On the opposite, ext3 constantly required ckfs.ext3, and sometimes died
>> so badly that even ckfs.ext3 could not recover it.

Depending on your storage, if barriers were not enabled on your storage,
this is expected.  Evaporating write caches on power cut do not play well
with journaling guarantees.

https://access.redhat.com/knowledge/docs/en-US/Red_Hat_Enterprise_Linux/6/html/Storage_Administration_Guide/writebarr.html

Barriers were not made default on ext3 until 2011, in kernel v3.1,
astonishingly.  So it makes sense that ext3 fared worse than ext4.

Unplayable journals are not surprising with non-battery-backed
writeback caches, no explicit cache flushing, and power loss.

> We ran about 6000 cycles of power resets with linux 2.6.37. The test
> was to run 3 tar processes unpacking linux kernel archive and power
> off after about 15 seconds. There were only 3 failures when file
> system couldn't be mounted, but that was due to HDD failure
> (unreadable sector in journal area). e2fsck successfully recovered
> those corruptions. As for software itself, there was no single issue
> and we never needed to run fsck after power loss. So I'd say that ext4
> is very tolerant to power losses at least in 2.6.37 assuming barriers
> and ordered data mode. I however understand this test is quite basic
> and any way results can be different for different kernels.

Right - barriers.

Of course you probably did lose *file* data even if the fs metadata
was correct.

Remember that journaling ensures a consistent metadata structure, but
does not guarantee data integrity.

-Eric

  parent reply	other threads:[~2012-11-16 16:26 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-14 10:41 ext4 settings in an embedded system Ohlsson, Fredrik (GE Healthcare, consultant)
2012-11-14 20:51 ` Theodore Ts'o
2012-11-15  8:42 ` Artem Bityutskiy
2012-11-15 10:01   ` Andrey Sidorov
2012-11-15 10:38     ` Artem Bityutskiy
2012-11-16 15:40     ` Eric Sandeen [this message]
2012-11-19 10:42       ` Artem Bityutskiy
2012-11-16 15:44   ` Eric Sandeen
2012-11-19 10:43     ` Artem Bityutskiy
2012-11-16 15:56 ` Eric Sandeen
2012-11-16 16:18 Ohlsson, Fredrik (GE Healthcare, consultant)
2012-11-16 16:58 ` Eric Sandeen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=50A65E5D.7040305@redhat.com \
    --to=sandeen@redhat.com \
    --cc=Fredrik.Ohlsson@ge.com \
    --cc=dedekind1@gmail.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=qrxd43@motorola.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.