From: Dave Chinner <david@fromorbit.com>
To: Anand Tiwari <tiwarikanand@gmail.com>
Cc: Eric Sandeen <sandeen@sandeen.net>, xfs@oss.sgi.com
Subject: Re: xfs_repair deleting realtime files.
Date: Fri, 28 Sep 2012 16:47:42 +1000 [thread overview]
Message-ID: <20120928064742.GE25626@dastard> (raw)
In-Reply-To: <CAHt31__59_XJw9EF7MniiYH5sS6CX44q9gGwxiqxx43k5OFZ4A@mail.gmail.com>
On Thu, Sep 27, 2012 at 07:27:16PM -0600, Anand Tiwari wrote:
> On Wed, Sep 26, 2012 at 12:17 AM, Dave Chinner <david@fromorbit.com> wrote:
>
> > On Tue, Sep 25, 2012 at 09:45:07PM -0600, Anand Tiwari wrote:
> > > thanks Dave for prompt reply, I meant to implement option 2 as you
> > > explained (option 3). I will start working on it tomorrow. In the mean
> > > time, I also had to put something in xfs_repair for the files which
> > > already exists on the disk. Would you guys willing to review/comment on
> > > that ?
> >
> > Sure.
> >
> > Cheers,
> >
> > Dave.
> > --
> > Dave Chinner
> > david@fromorbit.com
> >
>
> following are my changes for xfs_repair. my goal is to keep changes
> minimum as they may not included in upstream. I had to do these changes as
> we already have files with extent map not properly aligned.
> As we know, this happens only when we are growing a file in a realtime
> volume. by keeping this in mind, I am checking if start of a record in
> extent map is not aligned, check previous record and if they are
> contiguous, we can skip that part of record.
>
> let me know if you any issues with this or if someone has better approach.
> I would like to use pointers for prev and irec but again, I wanted to keep
> changes minimum
>
> thanks
> anand
>
>
> XFS currently can have records in extent map, which starts from unaligned
> block w.r.t rextsize.
>
> --------------------------------------
>
> xfs_repair considers this as a bug (multiple claims for a one real time
> extent) and deletes the file.
> This patch addresses the issue, by comparing current and previous records
> and make sure they are
> contiguous and not overlapped.
>
> diff --git a/repair/dinode.c b/repair/dinode.c
> index 5a2da39..5537f1c 100644
> --- a/repair/dinode.c
> +++ b/repair/dinode.c
> @@ -406,6 +406,7 @@ verify_agbno(xfs_mount_t *mp,
> static int
> process_rt_rec(
> xfs_mount_t *mp,
> + xfs_bmbt_irec_t *prev,
> xfs_bmbt_irec_t *irec,
> xfs_ino_t ino,
> xfs_drfsbno_t *tot,
Your mailer has removed all the whitespace from the patch. The files
Documentation/SubmittingPatches and Documentation/email-clients.txt
for help with how to send patches sanely via email. ;)
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2012-09-28 6:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-21 0:40 xfs_repair deleting realtime files Anand Tiwari
2012-09-21 5:00 ` Eric Sandeen
2012-09-21 15:51 ` Anand Tiwari
2012-09-21 16:07 ` Eric Sandeen
2012-09-21 16:40 ` Anand Tiwari
2012-09-24 7:55 ` Dave Chinner
2012-09-24 12:51 ` Anand Tiwari
2012-09-26 1:26 ` Anand Tiwari
2012-09-26 2:44 ` Dave Chinner
2012-09-26 3:45 ` Anand Tiwari
2012-09-26 6:17 ` Dave Chinner
2012-09-28 1:27 ` Anand Tiwari
2012-09-28 6:47 ` Dave Chinner [this message]
2012-09-29 22:49 ` Anand Tiwari
2012-10-02 0:59 ` Dave Chinner
2012-10-02 16:47 ` Anand Tiwari
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=20120928064742.GE25626@dastard \
--to=david@fromorbit.com \
--cc=sandeen@sandeen.net \
--cc=tiwarikanand@gmail.com \
--cc=xfs@oss.sgi.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