* xfs_getbmap assert
@ 2011-11-07 10:30 Christoph Hellwig
2011-11-07 20:15 ` Dave Chinner
0 siblings, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2011-11-07 10:30 UTC (permalink / raw)
To: xfs
With Dmitris fsstress updates I can hit the following assert fairly
regularly:
[11904.943956] XFS: Assertion failed: ((iflags & BMV_IF_DELALLOC) != 0) ||
(map[i].br_startblock != DELAYSTARTBLOCK), file:
/home/hch/work/linux-2.6/fs/xfs/xfs_bmap.c, line: 5604
which means we get an delalloc extent back from FIEMAP/GETBMAP despite
asking for a flush beforehand. While we hold the iolock over the call
and thus exclude new buffered writers from appearing that doesn't
prevent shared writeable mmaps from creating new delalloc extents.
I don't think this actually is a real issue, and a workaround would
be extremly hard. For now I've just remove the assert in my tree:
Index: xfs/fs/xfs/xfs_bmap.c
===================================================================
--- xfs.orig/fs/xfs/xfs_bmap.c 2011-11-05 09:02:24.410021945 +0100
+++ xfs/fs/xfs/xfs_bmap.c 2011-11-05 09:03:54.036494235 +0100
@@ -5600,8 +5600,6 @@ xfs_getbmap(
XFS_FSB_TO_BB(mp, map[i].br_blockcount);
out[cur_ext].bmv_unused1 = 0;
out[cur_ext].bmv_unused2 = 0;
- ASSERT(((iflags & BMV_IF_DELALLOC) != 0) ||
- (map[i].br_startblock != DELAYSTARTBLOCK));
if (map[i].br_startblock == HOLESTARTBLOCK &&
whichfork == XFS_ATTR_FORK) {
/* came to the end of attribute fork */
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: xfs_getbmap assert
2011-11-07 10:30 xfs_getbmap assert Christoph Hellwig
@ 2011-11-07 20:15 ` Dave Chinner
2011-11-14 20:05 ` Christoph Hellwig
0 siblings, 1 reply; 5+ messages in thread
From: Dave Chinner @ 2011-11-07 20:15 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: xfs
On Mon, Nov 07, 2011 at 05:30:37AM -0500, Christoph Hellwig wrote:
> With Dmitris fsstress updates I can hit the following assert fairly
> regularly:
>
> [11904.943956] XFS: Assertion failed: ((iflags & BMV_IF_DELALLOC) != 0) ||
> (map[i].br_startblock != DELAYSTARTBLOCK), file:
> /home/hch/work/linux-2.6/fs/xfs/xfs_bmap.c, line: 5604
>
> which means we get an delalloc extent back from FIEMAP/GETBMAP despite
> asking for a flush beforehand. While we hold the iolock over the call
> and thus exclude new buffered writers from appearing that doesn't
> prevent shared writeable mmaps from creating new delalloc extents.
Possibly. However, we might actually be tripping over speculative
delalloc regions beyond EOF - flushing will not convert those at
all. There's already a comment earlier on like this:
/*
* even after flushing the inode, there can still be delalloc
* blocks on the inode beyond EOF due to speculative
* preallocation. These are not removed until the release
* function is called or the inode is inactivated. Hence we
* cannot assert here that ip->i_delayed_blks == 0.
*/
Can you see if that is the case that is being triggered?
> I don't think this actually is a real issue, and a workaround would
> be extremly hard. For now I've just remove the assert in my tree:
Probably the right thing to do, anyway.
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: xfs_getbmap assert
2011-11-07 20:15 ` Dave Chinner
@ 2011-11-14 20:05 ` Christoph Hellwig
2011-11-15 20:02 ` Dave Chinner
0 siblings, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2011-11-14 20:05 UTC (permalink / raw)
To: Dave Chinner; +Cc: Christoph Hellwig, xfs
On Tue, Nov 08, 2011 at 07:15:05AM +1100, Dave Chinner wrote:
> Can you see if that is the case that is being triggered?
I've tried to reproduce the issue with additional debugging for almost
a week now, but I haven't been able to hit the assert again yet. Which
is strange given how often I managed to hit it just before.
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: xfs_getbmap assert
2011-11-14 20:05 ` Christoph Hellwig
@ 2011-11-15 20:02 ` Dave Chinner
2011-11-15 20:07 ` Christoph Hellwig
0 siblings, 1 reply; 5+ messages in thread
From: Dave Chinner @ 2011-11-15 20:02 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: xfs
On Mon, Nov 14, 2011 at 03:05:54PM -0500, Christoph Hellwig wrote:
> On Tue, Nov 08, 2011 at 07:15:05AM +1100, Dave Chinner wrote:
> > Can you see if that is the case that is being triggered?
>
> I've tried to reproduce the issue with additional debugging for almost
> a week now, but I haven't been able to hit the assert again yet. Which
> is strange given how often I managed to hit it just before.
Sounds exactly like the problems I've had trying to track this down
- as soon as you go looking for it, it disappears... :/
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: xfs_getbmap assert
2011-11-15 20:02 ` Dave Chinner
@ 2011-11-15 20:07 ` Christoph Hellwig
0 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2011-11-15 20:07 UTC (permalink / raw)
To: Dave Chinner; +Cc: xfs
On Wed, Nov 16, 2011 at 07:02:46AM +1100, Dave Chinner wrote:
> On Mon, Nov 14, 2011 at 03:05:54PM -0500, Christoph Hellwig wrote:
> > On Tue, Nov 08, 2011 at 07:15:05AM +1100, Dave Chinner wrote:
> > > Can you see if that is the case that is being triggered?
> >
> > I've tried to reproduce the issue with additional debugging for almost
> > a week now, but I haven't been able to hit the assert again yet. Which
> > is strange given how often I managed to hit it just before.
>
> Sounds exactly like the problems I've had trying to track this down
> - as soon as you go looking for it, it disappears... :/
I've actually reproduced it once today - of course that was running a
kernel without the debugging patch in it..
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2011-11-15 20:07 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-07 10:30 xfs_getbmap assert Christoph Hellwig
2011-11-07 20:15 ` Dave Chinner
2011-11-14 20:05 ` Christoph Hellwig
2011-11-15 20:02 ` Dave Chinner
2011-11-15 20:07 ` Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox