All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Murphy <lists@colorremedies.com>
To: Qu Wenruo <quwenruo.btrfs@gmx.com>
Cc: Sebastian Roller <sebastian.roller@gmail.com>,
	Btrfs BTRFS <linux-btrfs@vger.kernel.org>
Subject: Re: All files are damaged after btrfs restore
Date: Tue, 16 Mar 2021 20:59:40 -0600	[thread overview]
Message-ID: <CAJCQCtQ7o1_Kkxf3Gh8bM+r4-e3tXuZsFM1mHUQakRvJUA9mqA@mail.gmail.com> (raw)
In-Reply-To: <2411012e-0b50-ff76-2710-5fa55b8487eb@gmx.com>

On Tue, Mar 16, 2021 at 7:39 PM Qu Wenruo <quwenruo.btrfs@gmx.com> wrote:
> > Using that restore I was able to restore approx. 7 TB of the
> > originally stored 22 TB under that directory.
> > Unfortunately nearly all the files are damaged. Small text files are
> > still OK. But every larger binary file is useless.
> > Is there any possibility to fix the filesystem in a way, that I get
> > the data less damaged?
>
>  From the result, it looks like the on-disk data get (partially) wiped out.
> I doubt if it's just simple controller failure, but more likely
> something not really reaching disk or something more weird.

Hey Qu, thanks for the reply.

So it's not clear until further downthread that it's bcache in
writeback mode with an SSD that failed. And I've probably
underestimated the significance of how much data (in this case both
Btrfs metadata and user data) and for how long it can stay *only* on
the SSD with this policy.

https://bcache.evilpiepirate.org/ says it straight up, if using
writeback, it is not at all safe for the cache and backing devices to
be separated. If the cache device fails, everything on it is gone. By
my reading, for example, if the writeback percent is 50%, and the
cache device is 128G, at any given time 64G is *only* on the SSD.
There's no idle time flushing to the backing device that eventually
makes the backing device possibly a self sufficient storage device on
its own, it always needs the cache device.


-- 
Chris Murphy

  reply	other threads:[~2021-03-17  3:00 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-23 15:45 All files are damaged after btrfs restore Sebastian Roller
2021-02-25  5:40 ` Chris Murphy
2021-02-25  5:52   ` Chris Murphy
2021-02-26 16:01     ` Sebastian Roller
2021-02-27  1:04       ` Chris Murphy
2021-03-04 15:34         ` Sebastian Roller
2021-03-05  3:01           ` Chris Murphy
2021-03-07 13:58             ` Sebastian Roller
2021-03-08  0:56               ` Chris Murphy
2021-03-09 17:02                 ` Sebastian Roller
2021-03-09 20:34                   ` Chris Murphy
2021-03-16  9:35                     ` Sebastian Roller
2021-03-16 19:34                       ` Chris Murphy
2021-03-17  1:38 ` Qu Wenruo
2021-03-17  2:59   ` Chris Murphy [this message]
2021-03-17  9:01     ` Sebastian Roller
2021-03-17  1:54 ` Dāvis Mosāns
2021-03-17 10:50   ` Sebastian Roller

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=CAJCQCtQ7o1_Kkxf3Gh8bM+r4-e3tXuZsFM1mHUQakRvJUA9mqA@mail.gmail.com \
    --to=lists@colorremedies.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=quwenruo.btrfs@gmx.com \
    --cc=sebastian.roller@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 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.