linux/fs/xfs
Johannes Weiner 081003fff4 xfs: properly account for reclaimed inodes
When marking an inode reclaimable, a per-AG counter is increased, the
inode is tagged reclaimable in its per-AG tree, and, when this is the
first reclaimable inode in the AG, the AG entry in the per-mount tree
is also tagged.

When an inode is finally reclaimed, however, it is only deleted from
the per-AG tree.  Neither the counter is decreased, nor is the parent
tree's AG entry untagged properly.

Since the tags in the per-mount tree are not cleared, the inode
shrinker iterates over all AGs that have had reclaimable inodes at one
point in time.

The counters on the other hand signal an increasing amount of slab
objects to reclaim.  Since "70e60ce xfs: convert inode shrinker to
per-filesystem context" this is not a real issue anymore because the
shrinker bails out after one iteration.

But the problem was observable on a machine running v2.6.34, where the
reclaimable work increased and each process going into direct reclaim
eventually got stuck on the xfs inode shrinking path, trying to scan
several million objects.

Fix this by properly unwinding the reclaimable-state tracking of an
inode when it is reclaimed.

Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Cc: stable@kernel.org
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Alex Elder <aelder@sgi.com>
2010-10-06 22:35:48 -05:00
..
linux-2.6 xfs: properly account for reclaimed inodes 2010-10-06 22:35:48 -05:00
quota
support
Kconfig
Makefile
xfs.h
xfs_acl.h
xfs_ag.h
xfs_alloc.c
xfs_alloc.h
xfs_alloc_btree.c
xfs_alloc_btree.h
xfs_arch.h
xfs_attr.c
xfs_attr.h
xfs_attr_leaf.c
xfs_attr_leaf.h
xfs_attr_sf.h
xfs_bit.c
xfs_bit.h
xfs_bmap.c xfs: Make fiemap work with sparse files 2010-09-03 09:02:11 -05:00
xfs_bmap.h
xfs_bmap_btree.c
xfs_bmap_btree.h
xfs_btree.c
xfs_btree.h
xfs_btree_trace.c
xfs_btree_trace.h
xfs_buf_item.c
xfs_buf_item.h
xfs_da_btree.c
xfs_da_btree.h
xfs_dfrag.c
xfs_dfrag.h
xfs_dinode.h
xfs_dir2.c
xfs_dir2.h
xfs_dir2_block.c
xfs_dir2_block.h
xfs_dir2_data.c
xfs_dir2_data.h
xfs_dir2_leaf.c
xfs_dir2_leaf.h
xfs_dir2_node.c
xfs_dir2_node.h
xfs_dir2_sf.c
xfs_dir2_sf.h
xfs_error.c
xfs_error.h
xfs_extfree_item.c
xfs_extfree_item.h
xfs_filestream.c
xfs_filestream.h
xfs_fs.h xfs: Make fiemap work with sparse files 2010-09-03 09:02:11 -05:00
xfs_fsops.c xfs: dummy transactions should not dirty VFS state 2010-08-24 11:46:31 +10:00
xfs_fsops.h xfs: dummy transactions should not dirty VFS state 2010-08-24 11:46:31 +10:00
xfs_ialloc.c xfs: fix untrusted inode number lookup 2010-08-24 11:42:30 +10:00
xfs_ialloc.h
xfs_ialloc_btree.c
xfs_ialloc_btree.h
xfs_iget.c
xfs_inode.c xfs: ensure we mark all inodes in a freed cluster XFS_ISTALE 2010-08-24 11:42:41 +10:00
xfs_inode.h
xfs_inode_item.c
xfs_inode_item.h
xfs_inum.h
xfs_iomap.c
xfs_iomap.h
xfs_itable.c
xfs_itable.h
xfs_log.c
xfs_log.h
xfs_log_cil.c xfs: force background CIL push under sustained load 2010-09-29 07:51:03 -05:00
xfs_log_priv.h xfs: force background CIL push under sustained load 2010-09-29 07:51:03 -05:00
xfs_log_recover.c
xfs_log_recover.h
xfs_mount.c
xfs_mount.h
xfs_mru_cache.c
xfs_mru_cache.h
xfs_quota.h
xfs_refcache.h
xfs_rename.c
xfs_rtalloc.c
xfs_rtalloc.h
xfs_rw.c
xfs_rw.h
xfs_sb.h
xfs_trans.c xfs: unlock items before allowing the CIL to commit 2010-08-24 11:42:52 +10:00
xfs_trans.h
xfs_trans_ail.c
xfs_trans_buf.c
xfs_trans_extfree.c
xfs_trans_inode.c
xfs_trans_priv.h xfs: unlock items before allowing the CIL to commit 2010-08-24 11:42:52 +10:00
xfs_trans_space.h
xfs_types.h
xfs_utils.c
xfs_utils.h
xfs_vnodeops.c xfs: prevent 32bit overflow in space reservation 2010-09-03 12:19:33 +10:00
xfs_vnodeops.h