xfs
[Top] [All Lists]

Re: xfs resize: primary superblock is not updated immediately

To: Alex Lyakas <alex@xxxxxxxxxxxxxxxxx>
Subject: Re: xfs resize: primary superblock is not updated immediately
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Wed, 24 Feb 2016 09:59:26 +1100
Cc: xfs@xxxxxxxxxxx, Christoph Hellwig <hch@xxxxxxxxxxxxx>, Danny Shavit <danny@xxxxxxxxxxxxxxxxx>, Yair Hershko <yair@xxxxxxxxxxxxxxxxx>, Shyam Kaushik <shyam@xxxxxxxxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <D5578D3E98EE48B88EA9A1126B671155@alyakaslap>
References: <3685DFAD20214109878873CF81232704@alyakaslap> <20160222212019.GI25832@dastard> <CAOcd+r1XY2kcp+qJ=mPOAQSmb90QUnLfmT3-FkMjQN_+Ejmt8A@xxxxxxxxxxxxxx> <20160222235628.GK25832@dastard> <D5578D3E98EE48B88EA9A1126B671155@alyakaslap>
User-agent: Mutt/1.5.21 (2010-09-15)
On Tue, Feb 23, 2016 at 02:25:38PM +0200, Alex Lyakas wrote:
> Hi Dave,
> 
> Below is a detailed reproduction scenario of the problem.

Can you package this for xfstests and send to
fstests@xxxxxxxxxxxxxxx, please?

> No
> snapshots involved, only XFS. The scenario is performed on a VM,
> running kernel 3.18.19.

And a current kernel (e.g. 4.5-rc5) behaves how?

> 9) mount
> # mount -o sync /dev/mapper/xfs_base /mnt/xfs/
> 
> Kernel panics with [2].

It tried to read a buffer beyond the current end of filesystem that
log recoery knows about. Given the on-disk superblock had not been
updated by the growfs operation, this should have been detected
by _xfs_buf_find() and errored out, not tried to look up a per-ag
structure that is beyond the current end of filesystem.

i.e. the code I pointed out in my previous email failed to detect
the situation is it supposed to be protecting against.  Why did that
"block beyond the end of the filesystem" detection fail?

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx

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