linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Anand Jain <anand.jain@oracle.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH v7 RESEND Rebased] btrfs-progs: dump-tree: add noscan option
Date: Wed, 3 Jul 2019 14:53:09 +0200	[thread overview]
Message-ID: <20190703125309.GT20977@twin.jikos.cz> (raw)
In-Reply-To: <20190626083017.1833-1-anand.jain@oracle.com>

On Wed, Jun 26, 2019 at 01:30:17AM -0700, Anand Jain wrote:
> From: Anand Jain <Anand.Jain@oracle.com>
> 
> The cli 'btrfs inspect dump-tree <dev>' will scan for the partner devices
> if any by default.
> 
> So as of now you can not inspect each mirrored device independently.
> 
> This patch adds noscan option, which when used won't scan the system for
> the partner devices, instead it just uses the devices provided in the
> argument.
> 
> For example:
>   btrfs inspect dump-tree --noscan <dev> [<dev>..]
> 
> This helps to debug degraded raid1 and raid10.
> 
> Signed-off-by: Anand Jain <anand.jain@oracle.com>

Added to devel, with some minor tweaks. Sorry for the delay.

> ---
> v6->v7: rebase on latest btrfs-progs::devel
> v5->v6: rebase on latest btrfs-progs::devel
> v4->v5: nit: use %m to print error string.
> 	changelog update.
> v3->v4: change the patch title.
> 	collapse scan_args() to its only parent cmd_inspect_dump_tree()
> 	(it was bit confusing).
> 	update the change log.
> 	update usage.
> 	update man page.
> v2->v3: make it scalable for more than two disks in noscan mode
> v1->v2: rename --degraded to --noscan
>  Documentation/btrfs-inspect-internal.asciidoc |  5 +-
>  cmds-inspect-dump-tree.c                      | 53 ++++++++++++++-----
>  2 files changed, 45 insertions(+), 13 deletions(-)
> 
> diff --git a/Documentation/btrfs-inspect-internal.asciidoc b/Documentation/btrfs-inspect-internal.asciidoc
> index 210f18c30a40..c9962ab3b548 100644
> --- a/Documentation/btrfs-inspect-internal.asciidoc
> +++ b/Documentation/btrfs-inspect-internal.asciidoc
> @@ -61,7 +61,7 @@ specify which mirror to print, valid values are 0, 1 and 2 and the superblock
>  must be present on the device with a valid signature, can be used together with
>  '--force'
>  
> -*dump-tree* [options] <device>::
> +*dump-tree* [options] <device> [device...]::
>  (replaces the standalone tool *btrfs-debug-tree*)
>  +
>  Dump tree structures from a given device in textual form, expand keys to human
> @@ -95,6 +95,9 @@ intermixed in the output
>  --bfs::::
>  use breadth-first search to print trees. the nodes are printed before all
>  leaves
> +--device::::

Minor typo, --noscan, fixed.

  parent reply	other threads:[~2019-07-03 12:52 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-26  8:30 [PATCH v7 RESEND Rebased] btrfs-progs: dump-tree: add noscan option Anand Jain
2019-07-02  8:09 ` Anand Jain
2019-07-03 12:53 ` David Sterba [this message]
2019-07-03 13:02 ` David Sterba
2019-07-03 16:09 ` David Sterba
2019-07-03 22:16   ` Anand Jain
2019-07-03 23:39     ` David Sterba
2019-07-04  1:29       ` Anand Jain

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=20190703125309.GT20977@twin.jikos.cz \
    --to=dsterba@suse.cz \
    --cc=anand.jain@oracle.com \
    --cc=linux-btrfs@vger.kernel.org \
    /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).