xfs-masters
[Top] [All Lists]

[xfs-masters] [Bug 10421] Filesystem failing without any warning or etc

To: xfs-masters@xxxxxxxxxxx
Subject: [xfs-masters] [Bug 10421] Filesystem failing without any warning or etc
From: bugme-daemon@xxxxxxxxxxxxxxxxxxx
Date: Wed, 14 May 2008 10:26:30 -0700 (PDT)
In-reply-to: <bug-10421-470@xxxxxxxxxxxxxxxxxxxxxxxx/>
Reply-to: xfs-masters@xxxxxxxxxxx
Sender: xfs-masters-bounce@xxxxxxxxxxx
http://bugzilla.kernel.org/show_bug.cgi?id=10421





------- Comment #48 from sandeen-xfs@xxxxxxxxxxx  2008-05-14 10:26 -------
so my hunch is that this part of the patch:

@@ -1191,7 +1164,7 @@ _xfs_buf_ioapply(
        /* Special code path for reading a sub page size buffer in --
         * we populate up the whole page, and hence the other metadata
         * in the same page.  This optimization is only valid when the
         * filesystem block size is not smaller than the page size.
         */

        if ((bp->b_buffer_length < PAGE_CACHE_SIZE) &&
-           (bp->b_flags & XBF_READ) && locking &&
+           (bp->b_flags & XBF_READ) &&
            (blocksize >= PAGE_CACHE_SIZE)) {
                bio = bio_alloc(GFP_NOIO, 1);

is allowing another metadata read to clobber our agi with on-disk data after
it's been updated.

Some tracing showed:

<7>3438/2 xfs_iunlink ino 268640385 agibp ffff81001c1533c0
<7>3438/2 xfs_iunlink:1995: agi bp ffff81001c1533c0
ffff81000f19b400->agi_unlinked[1] set to agino 204929
<7>3437/2 xfs_iunlink_remove ino 134217857
[0]more>
<7>3437/2 xfs_iunlink_remove:2120: agi bp ffff81000e8a9840
ffff81001e1c1400->agi_unlinked[1] set to next_agino  4294967295
<7>3438/0 xfs_iunlink_remove ino 268640385
<4>3438/0 xfs_iunlink_remove:2078: agi bp ffff81001c1533c0
ffff81000f19b400->agi_unlinked[1] == NULLAGINO

... without any code assignments in between, we went from the proper value back
to NULLAGINO (disk value)

I think this optimization is not honoring the locking for the other xfs_bufs
around it, since it used to be page-based but is now per-bp.


-- 
Configure bugmail: http://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


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