xfs
[Top] [All Lists]

TAKE - XFS allocator can spin forever in full filesystem]

To: linux-xfs@xxxxxxxxxxx
Subject: TAKE - XFS allocator can spin forever in full filesystem]
From: Steve Lord <lord@xxxxxxx>
Date: 14 Jun 2002 13:15:57 -0500
Sender: owner-linux-xfs@xxxxxxxxxxx
Date:  Fri Jun 14 11:03:36 PDT 2002
Workarea:  jen.americas.sgi.com:/src/lord/xfs-linux.2.4

The following file(s) were checked into:
  bonnie.engr.sgi.com:/isms/slinx/2.4.x-xfs


Modid:  2.4.x-xfs:slinx:121630a
linux/fs/xfs/xfs_alloc.c - 1.152
        - add an extra last pass to the allocation group scan to squeeze the 
last
          few blocks out of the disk.

linux/fs/xfs/linux/xfs_lrw.c - 1.148
        - when out of space, flush the log as well as the delalloc buffers
Description :
We came across an end case on linux where a filesystem had a few blocks
free and was continually spinning in the strategy path attempting to
allocate space for a delalloc block.

xfs_alloc_vextent is responsible for locating an allocation group
for the space. In the case where a specific allocation group has been
requested, the restriction on leaving some blocks free in the ag
is lifted by this function:

        args->minleft = 0;
        xfs_alloc_fix_freelist(args, 0);

In the case where we are scanning all allocation groups for space, we never
do that. I propose adding a third pass to the loop which scans the ags for
space. In this third pass we would drop the minleft parameter down to zero
which would allow us to extract blocks from the agfl to satisfy the request.


-- 

Steve Lord                                      voice: +1-651-683-3511
Principal Engineer, Filesystem Software         email: lord@xxxxxxx


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