lkml.org 
[lkml]   [2004]   [Dec]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Reducing inode cache usage on 2.4?

James,

Can apply Andrew's patch and examine the results?

I've merged it to mainline because it looks sensible.

Thanks Andrew!

On Fri, Dec 17, 2004 at 05:21:04PM -0800, Andrew Morton wrote:
> James Pearson <james-p@moving-picture.com> wrote:
> >
> > It seems the inode cache has priority over cached file data.
>
> It does. If the machine is full of unmapped clean pagecache pages the
> kernel won't even try to reclaim inodes. This should help a bit:
>
> --- 24/mm/vmscan.c~a 2004-12-17 17:18:31.660254712 -0800
> +++ 24-akpm/mm/vmscan.c 2004-12-17 17:18:41.821709936 -0800
> @@ -659,13 +659,13 @@ int fastcall try_to_free_pages_zone(zone
>
> do {
> nr_pages = shrink_caches(classzone, gfp_mask, nr_pages, &failed_swapout);
> - if (nr_pages <= 0)
> - return 1;
> shrink_dcache_memory(vm_vfs_scan_ratio, gfp_mask);
> shrink_icache_memory(vm_vfs_scan_ratio, gfp_mask);
> #ifdef CONFIG_QUOTA
> shrink_dqcache_memory(vm_vfs_scan_ratio, gfp_mask);
> #endif
> + if (nr_pages <= 0)
> + return 1;
> if (!failed_swapout)
> failed_swapout = !swap_out(classzone);
> } while (--tries);
> _
>
>
> > What triggers the 'normal ageing round'? Is it possible to trigger this
> > earlier (at a lower memory usage), or give a higher priority to cached data?
>
> You could also try lowering /proc/sys/vm/vm_mapped_ratio. That will cause
> inodes to be reaped more easily, but will also cause more swapout.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:08    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site