Re: [RFC][PATCH 2/2] nfs: scale writeback threshold proportional to dirty threshold

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



An update from Feng:

Subject: nfs: fix a bug about adjusting nfs_congestion_kb
Date: Tue Oct 18 12:47:58 CST 2011

From: "Tang, Feng" <feng.tang@xxxxxxxxx>

The VM dirty_thresh may be set to very small(even 0) by wired user, in
such case, nfs_congestion_kb may be adjusted to 0, will cause the normal
NFS write function get congested and deaklocked. So let's set the bottom
line of nfs_congestion_kb to 128kb.

Signed-off-by: Feng Tang <feng.tang@xxxxxxxxx>
Signed-off-by: Wu Fengguang <fengguang.wu@xxxxxxxxx>
---
 fs/nfs/write.c |    1 +
 1 file changed, 1 insertion(+)

--- linux-next.orig/fs/nfs/write.c	2011-10-17 16:07:40.000000000 +0800
+++ linux-next/fs/nfs/write.c	2011-10-18 12:47:46.000000000 +0800
@@ -1814,6 +1814,7 @@ void nfs_update_congestion_thresh(void)
 	 */
 	global_dirty_limits(&background_thresh, &dirty_thresh);
 	dirty_thresh <<= PAGE_SHIFT - 10;
+	dirty_thresh += 1024;
 
 	if (nfs_congestion_kb > dirty_thresh / 8)
 		nfs_congestion_kb = dirty_thresh / 8;
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux