public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Qu Wenruo <wqu@suse.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH 0/2] btrfs-progs: add check and repair ability for super num devices mismatch
Date: Wed, 23 Mar 2022 18:12:49 +0100	[thread overview]
Message-ID: <20220323171249.GA2237@twin.jikos.cz> (raw)
In-Reply-To: <cover.1646009185.git.wqu@suse.com>

On Mon, Feb 28, 2022 at 08:50:06AM +0800, Qu Wenruo wrote:
> The patchset can be fetched from github:
> https://github.com/adam900710/btrfs-progs/tree/super_num_devs
> 
> The 2nd patch contains a compressed raw image, thus it may be a little
> too large for the mail list.
> 
> This patchset will allow btrfs check to detect and repair super num devices
> mismatch.
> 
> The detect part is to iterate through chunk tree to grab the correct
> number of devices.
> This is more reliable than counting devices in fs_devices, since seed
> device is in another fs_devices.
> 
> The repair is more straightforward, just reset the value in superblock
> and commit a transaction.

As repair it should work and be safe, also it should be reasonably safe
to be part of --repair. In addition to that we may also want the rescue
subcommand as it's meant to be for such one-time fixes for specific
errors.

  parent reply	other threads:[~2022-03-23 17:16 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-28  0:50 [PATCH 0/2] btrfs-progs: add check and repair ability for super num devices mismatch Qu Wenruo
2022-02-28  0:50 ` [PATCH 1/2] btrfs-progs: check: add check and repair ability for super num devs mismatch Qu Wenruo
2022-03-23 17:43   ` David Sterba
2022-03-23 23:15     ` Qu Wenruo
2022-03-23 23:38       ` Qu Wenruo
2022-02-28  0:50 ` [PATCH 2/2] btrfs-progs: tests/fsck: add test case " Qu Wenruo
2022-03-23 17:12 ` David Sterba [this message]
2022-03-23 17:17 ` [PATCH 0/2] btrfs-progs: add check and repair ability for super num devices mismatch David Sterba
2022-03-23 23:30   ` Qu Wenruo
2022-03-24 15:12     ` David Sterba

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=20220323171249.GA2237@twin.jikos.cz \
    --to=dsterba@suse.cz \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=wqu@suse.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