Bug#589294: Crashes / traces after copying large files over NFS
Package: linux-2.6
Version: 2.6.32-15
Severity: important
This bug in present in all 2.6.32.x, 33.x and 34.x kernels.
It is a regression in NFS code. When copying a large file (larger than
the amount of available physical memory) to an NFS-mounted filesystem,
swapper and rpciod on the client complain about page allocation failures
and then kswapd goes into a deadlock, resulting in a system-wide crash.
kswapd sets the GFP_KERNEL allocation flags, but is still liable to cause
the system to lock up if it has to wait too long for an RPC call etc to
succeed.
- /* Only do I/O if gfp is a superset of GFP_KERNEL */
- if ((gfp & GFP_KERNEL) == GFP_KERNEL)
+ /* Only do I/O if gfp is a superset of GFP_KERNEL and if
+ * we're not kswapd or some other memory allocator.
+ */
+ if ((gfp & GFP_KERNEL) == GFP_KERNEL
+ && !(current->flags & PF_MEMALLOC))
nfs_wb_page(page->mapping->host, page);
/* If PagePrivate() is set, then the page is not freeable */
if (PagePrivate(page))
--
Leszek "Tygrys" Urbanski, SCSA, SCNA
"Unix-to-Unix Copy Program;" said PDP-1. "You will never find a more
wretched hive of bugs and flamers. We must be cautious." -- DECWARS
http://cygnus.moo.pl/ -- Cygnus High Altitude Balloon
--
To UNSUBSCRIBE, email to debian-kernel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20100716134322.GA27225@moo.pl">http://lists.debian.org/20100716134322.GA27225@moo.pl