Re: [PATCH] nfs: writeback pages wait queue

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

 



Hi Jim,

On Sat, Nov 19, 2011 at 09:44:12PM +0800, Jim Rees wrote:
> Wu Fengguang wrote:
> 
>   The generic writeback routines are departing from congestion_wait()
>   in preference of get_request_wait(), aka. waiting on the block queues.
>   
>   Introduce the missing writeback wait queue for NFS, otherwise its
>   writeback pages will grow greedily, exhausting all PG_dirty pages.
>   
>   Tests show that it can effectively reduce stalls in the disk-network
>   pipeline, improve performance and reduce delays.
> 
> This is great stuff.  Did you do any tests on long delay paths?  I did some
> work on this a few years ago and made some progress but not enough.

Good question! I didn't test fat pipelines, which sure asks for reasonably high
nfs_congestion_kb to work well.

However we have good chances.

The nfs_congestion_kb is computed at module loading time in
nfs_init_writepagecache():

        /*
         * NFS congestion size, scale with available memory.
         *
         *  64MB:    8192k
         * 128MB:   11585k
         * 256MB:   16384k
         * 512MB:   23170k
         *   1GB:   32768k
         *   2GB:   46340k
         *   4GB:   65536k
         *   8GB:   92681k
         *  16GB:  131072k
         *
         * This allows larger machines to have larger/more transfers.
         * Limit the default to 256M
         */

For a typical mem=4GB client, nfs_congestion_kb=64MB, which is enough
to fill a 100ms*100MB/s=10MB network pipeline.

There may be more demanding ones, however that's rare case and its
user should be fully aware of the specialness and the need to do some
hand tuning, for example:

        echo $(300<<10) > /proc/sys/fs/nfs/nfs_congestion_kb

Thanks,
Fengguang
--
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