Index: linux-2.6.16-rc1-mm2/mm/vmscan.c =================================================================== --- linux-2.6.16-rc1-mm2.orig/mm/vmscan.c 2006-01-24 08:52:14.000000000 -0800 +++ linux-2.6.16-rc1-mm2/mm/vmscan.c 2006-01-24 08:52:44.000000000 -0800 @@ -1832,6 +1832,7 @@ int zone_reclaim_mode __read_mostly; #define RECLAIM_WRITE (1<<1) /* Writeout pages during reclaim */ #define RECLAIM_SWAP (1<<2) /* Swap pages out during reclaim */ #define RECLAIM_SLAB (1<<3) /* Do a global slab shrink if the zone is out of memory */ +#define RECLAIM_DEBUG (1<<10) /* trace zone reclaim behavior */ /* * Mininum time between zone reclaim scans @@ -1895,6 +1896,10 @@ int zone_reclaim(struct zone *zone, gfp_ sc.priority--; shrink_zone(zone, &sc); + if (zone_reclaim_mode & RECLAIM_DEBUG) + printk(KERN_INFO "Zone reclaim priority=%d Scanned=%lu Reclaimed=%lu\n", + sc.priority, sc.nr_scanned, sc.nr_reclaimed); + } while (sc.nr_reclaimed < nr_pages && sc.priority > 0); if (sc.nr_reclaimed < nr_pages && (zone_reclaim_mode & RECLAIM_SLAB)) { Index: linux-2.6.16-rc1-mm2/Documentation/sysctl/vm.txt =================================================================== --- linux-2.6.16-rc1-mm2.orig/Documentation/sysctl/vm.txt 2006-01-24 08:52:14.000000000 -0800 +++ linux-2.6.16-rc1-mm2/Documentation/sysctl/vm.txt 2006-01-24 08:53:19.000000000 -0800 @@ -137,6 +137,7 @@ This is a ORed together value of 2 = Zone reclaim writes dirty pages out 4 = Zone reclaim swaps pages 8 = Also do a global slab reclaim pass +1024 = Zone reclaim debug printks zone_reclaim_mode is set during bootup to 1 if it is determined that pages from remote zones will cause a significant performance reduction. The