NFS Performance

Steven Johnson sjohnson at sakuraindustries.com
Sat Sep 16 00:11:21 UTC 2006


Hi

>Sound's fine.  Changing it there is quite easy.  I think it should
>default to 8K, and let the user tune it down by way of a sysctl.  Ill
>have the code added and tested, if it turns out OK, (which i suspect it
>will) I will post the patch.
>  
>
As promised, see attached patches. 1 for nfs.h, and 2 for nfs.c

The nfs.h patch and 1 of the nfs.c patches
(nfs_settable_buffer_size.patch) are for the  HAVE_BLKSIZE define.

The way we approached it is that if HAVE_BLKSIZE is defined, then an
extra parameter must be passed to nfs_init, specifying the size of the
block to use. If 0 is passed for this, it defaults to the best block
size (which seems to be 8K for us).  Any other value up to 8K sets the
block size to this (over 8K sets it to 8K).  Then the code changes in
nfs.c are also controller by the same #def.  The reason we did it this
way, is so that if this define is not used, the existing behaviour will
prevail.  If this is defined, then the new behaviour kicks in and the
block size must be specified when nfs is initialised.  We couldn't see
any value in it being able to be changed on the fly after
initialisation.  For debug purposes, it is a stored as a static
variable, and so could be changed by a debugger to test different block
sizes very easily.

The second patch to nfs.c is in regard to the big pool which was only
being used  on a symlink and a write, it is equally useful for a read so
this patch allows  the pool to be big pool on a read, instead of small
pool as it does now.  I don't know if this makes things better, but it
certainly doesn't hurt (us anyway).

Steven Johnson

-------------- next part --------------
A non-text attachment was scrubbed...
Name: librtemsNfs_settable_buffer_size.patch
Type: text/x-patch
Size: 364 bytes
Desc: not available
URL: <http://lists.rtems.org/pipermail/users/attachments/20060916/8d6b2c1d/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: nfs_read_bigpool.patch
Type: text/x-patch
Size: 279 bytes
Desc: not available
URL: <http://lists.rtems.org/pipermail/users/attachments/20060916/8d6b2c1d/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: nfs_settable_buffer_size.patch
Type: text/x-patch
Size: 1719 bytes
Desc: not available
URL: <http://lists.rtems.org/pipermail/users/attachments/20060916/8d6b2c1d/attachment-0002.bin>


More information about the users mailing list