All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Foster <bfoster@redhat.com>
To: Eric Sandeen <sandeen@redhat.com>
Cc: linux-xfs <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH] xfs_repair: don't indicate dirtiness if FSGEOMETRY fails
Date: Fri, 16 Dec 2016 12:42:58 -0500	[thread overview]
Message-ID: <20161216174258.GH8447@bfoster.bfoster> (raw)
In-Reply-To: <fceea296-989c-a71d-a6e7-23560fd6db8b@redhat.com>

On Fri, Dec 16, 2016 at 09:56:19AM -0600, Eric Sandeen wrote:
> Today, pointing repair at an image hosted on a non-xfs
> filesystem will result in a XFS_IOC_FSGEOMETRY_V1 failure,
> but repair generally proceeds without further problems.
> 
> However, calling do_warn() sets fs_is_dirty to 1, so
> xfs_repair -n exits with non-zero status, indicating
> corruption.  This is incorrect.
> 
> Change the message to use do_log so that it does not
> incorrectly indicate corruption.
> 
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> --- 

Reviewed-by: Brian Foster <bfoster@redhat.com>

> 
> diff --git a/repair/xfs_repair.c b/repair/xfs_repair.c
> index d950a32..5c79fd9 100644
> --- a/repair/xfs_repair.c
> +++ b/repair/xfs_repair.c
> @@ -696,7 +696,7 @@ main(int argc, char **argv)
>  		struct xfs_fsop_geom_v1 geom = { 0 };
>  
>  		if (ioctl(fd, XFS_IOC_FSGEOMETRY_V1, &geom) < 0) {
> -			do_warn(_("Cannot get host filesystem geometry.\n"
> +			do_log(_("Cannot get host filesystem geometry.\n"
>  		"Repair may fail if there is a sector size mismatch between\n"
>  		"the image and the host filesystem.\n"));
>  			geom.sectsize = BBSIZE;
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2016-12-16 17:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-16 15:56 [PATCH] xfs_repair: don't indicate dirtiness if FSGEOMETRY fails Eric Sandeen
2016-12-16 17:42 ` Brian Foster [this message]
2016-12-19 10:24 ` Christoph Hellwig

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=20161216174258.GH8447@bfoster.bfoster \
    --to=bfoster@redhat.com \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@redhat.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.