From: Hugo Mills <hugo@carfax.org.uk>
To: Rain Maker <rainmaker52@gmail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Recovering from csum errors
Date: Mon, 2 Sep 2013 23:00:06 +0100 [thread overview]
Message-ID: <20130902220006.GA6389@carfax.org.uk> (raw)
In-Reply-To: <CAD+_0YrG2ju47suCSRKta+bONwUPcjTpv1y=11rkVNqVtHHwiQ@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2175 bytes --]
On Mon, Sep 02, 2013 at 11:41:12PM +0200, Rain Maker wrote:
> Hello list,
>
> So, I ran a full scrub, and, luckily, it only found 6 csum errors
> (these 6). The damage therefore seems to be contained in "just" 1
> file.
>
> Now, I removed the offending file. But is there something else I
> should have done to recover the data in this file? Can it be
> recovered?
No, and no. The data's failing a checksum, so it's basically
broken. If you had a btrfs RAID-1 configuration, the FS would be able
to recover from one broken copy using the other (good) copy.
> I'm running 3.11-rc7. It is a single disk btrfs filesystem. I have
> several subvolumes defined, one of which for VMWare Workstation (on
> which the corruption took place).
Aaah, the VM workload could explain this. There's some (known,
won't-fix) issues with (I think) direct-IO in VM guests that can cause
bad checksums to be written under some circumstances.
I'm not 100% certain, but I _think_ that making your VM images
nocow (create an empty file with touch; use chattr +C; extend the file
to the right size) may help prevent these problems.
> I checked the SMART values, they all seem OK. The harddisks in this
> machine are less then a month old. I replaced them after seeing
> similar messages on the "old" disks.
>
> Is the only logical explanation for this some kind of hardware failure
> (SATA controller, power supply...), or could there be something more
> to this?
As above, there's some direct-IO problems with data changing
in-flight that can lead to bad checksums. Fixing the issue would cause
some fairly serious slow-downs in performance for that case, which is
rather against what direct-IO is trying to do, so I think it's
unlikely the behaviour will be changed.
Of course, I could be completely wrong about all this, and you've
got bad RAM or PSU something...
Hugo.
--
=== Hugo Mills: hugo@... carfax.org.uk | darksatanic.net | lug.org.uk ===
PGP key: 65E74AC0 from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
--- "What are we going to do tonight?" "The same thing we do ---
every night, Pinky. Try to take over the world!"
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
next prev parent reply other threads:[~2013-09-02 22:00 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-02 21:41 Recovering from csum errors Rain Maker
2013-09-02 22:00 ` Hugo Mills [this message]
2013-09-02 22:28 ` Rain Maker
[not found] ` < CAD+_0YqsQRO90Lx1R64h8EE-L=4zrE6CEQGDKy-h=92hLLptWw@mail.gmail.com>
2013-09-03 8:54 ` Duncan
2013-09-03 9:26 ` David MacKinnon
[not found] ` < pan$97a5$71cfb7f0$286a61f9$62ed2e15@cox.net>
[not found] ` < CAA1QwTbiYGWpxctxOrF67wOzdAr6U6TKR__HZW44c2q9XeVM2w@mail.gmail.com>
2013-09-03 16:08 ` Duncan
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=20130902220006.GA6389@carfax.org.uk \
--to=hugo@carfax.org.uk \
--cc=linux-btrfs@vger.kernel.org \
--cc=rainmaker52@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).