xfs
[Top] [All Lists]

Re: new fs, xfs_admin new label, metadata corruption detected

To: Chris Murphy <lists@xxxxxxxxxxxxxxxxx>
Subject: Re: new fs, xfs_admin new label, metadata corruption detected
From: Zorro Lang <zlang@xxxxxxxxxx>
Date: Fri, 18 Mar 2016 12:43:31 +0800
Cc: Dave Chinner <david@xxxxxxxxxxxxx>, Eric Sandeen <sandeen@xxxxxxxxxxx>, "xfs@xxxxxxxxxxx" <xfs@xxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <CAJCQCtTZ_sS9TGTDvzCcD5P2biKznsvx1XnrKv3KC9ZynrJsYA@xxxxxxxxxxxxxx>
References: <CAJCQCtR4tq8+BXRX+Y4rkqn6ZrFLw-9SX=gXKkF3QS1b2c8Ksg@xxxxxxxxxxxxxx> <56E8AA22.7080301@xxxxxxxxxxx> <CAJCQCtQYMitUvPN1ORyEHvDhddJ09Hp_xK_CBc0e1Cu972S3_w@xxxxxxxxxxxxxx> <CAJCQCtQJ_1ARXYuN3j2VyVN8FBtG0myqmPnOgco1v-tQxqmyBg@xxxxxxxxxxxxxx> <20160317205729.GL30721@dastard> <CAJCQCtTZ_sS9TGTDvzCcD5P2biKznsvx1XnrKv3KC9ZynrJsYA@xxxxxxxxxxxxxx>
User-agent: Mutt/1.5.24 (2015-08-30)
On Thu, Mar 17, 2016 at 05:21:51PM -0600, Chris Murphy wrote:
> On Thu, Mar 17, 2016 at 2:57 PM, Dave Chinner <david@xxxxxxxxxxxxx> wrote:
> > On Wed, Mar 16, 2016 at 08:39:21PM -0600, Chris Murphy wrote:
> >> OK I can consistently reproduce this on the CLI. I end up with totally 
> >> different
> >>
> >> # lvcreate -L 40g VG -n testxfs
> >>   Logical volume "testxfs" created.
> > ....
> > [grow]
> > ....
> >> # xfs_repair -n /dev/VG/testxfs
> >> Phase 1 - find and verify superblock...
> >> Phase 2 - using internal log
> >>         - zero log...
> >>         - scan filesystem freespace and inode maps...
> >> Metadata corruption detected at xfs_agf block 0x8c00008/0x1000
> >> fllast 1014 in agf 7 too large (max = 1014)
> >> Metadata corruption detected at xfs_agf block 0x6400008/0x1000
> >> fllast 1014 in agf 5 too large (max = 1014)
> >> Metadata corruption detected at xfs_agf block 0x5000008/0x1000
> >> fllast 1014 in agf 4 too large (max = 1014)
> >> Metadata corruption detected at xfs_agf block 0x7800008/0x1000
> >> fllast 1014 in agf 6 too large (max = 1014)
> >>         - found root inode chunk
> >
> > That's caused by commit 96f859d ("libxfs: pack the agfl header
> > structure so XFS_AGFL_SIZE is correct") and growfs setting the
> > last free list entry to something that a userspace without the
> > commit  9fccb9f ("libxfs: pack the agfl header structure so
> > XFS_AGFL_SIZE is correct") fails to validate correctly.
> >
> > i.e. update userspace to 4.5.0, and the repair noise will go away.
> 
> Yep. The problem is not reproducible with xfsprogs 4.5.0.

HaHa, Dave always knows more XFS change history:)

BTW, this bug don't need LVM resize, just need
---
  mkfs.xfs -d size=$half_size $dev
  mount $dev $mnt
  xfs_growfs -d $mnt
  umount $mnt
  xfs_repair -n $dev
---
to reproduce it.

And I think xfstests xfs/015 can cover this test.

Thanks,
Zorro
> 
> 

<Prev in Thread] Current Thread [Next in Thread>