Terrible NFS performance under 9.2-RELEASE?

Rick Macklem rmacklem at uoguelph.ca
Mon Feb 10 00:54:23 UTC 2014


Christian Weisgerber wrote:
> Rick Macklem <rmacklem at uoguelph.ca> wrote:
> 
> > I have a "hunch" that might explain why 64K NFS reads/writes
> > perform
> > poorly for some network environments.
> > A 64K NFS read reply/write request consists of a list of 34 mbufs
> > when
> > passed to TCP via sosend() and a total data length of around
> > 65680bytes.
> > Looking at a couple of drivers (virtio and ixgbe), they seem to
> > expect
> > no more than 32-33 mbufs in a list for a 65535 byte TSO xmit. I
> > think
> > (I don't have anything that does TSO to confirm this) that NFS will
> > pass
> > a list that is longer (34 plus a TCP/IP header).
> 
> This may or may not be the same problem:
> 
> When I switched my desktop box from FreeBSD 7 to 9, NFS read
> performance from my media server (running OpenBSD) became extremely
> poor.  I couldn't even stream a movie any longer.  Disabling TSO
> on the nfe(4) interface had no effect.  My workaround was to switch
> from a TCP mount to a UDP one.  The problem has persisted to FreeBSD
> 10.
> 
> I can now report that switching to [rw]size=32768 with a TCP mount
> also works fine.
> 
If it is convenient, trying a 64K TCP mount with a kernel that has the
attached patch (which makes it use page size clusters and reduces the
# of segments to 18) to see if it works well, would be interesting.

rick
ps: This is not a patch destined for head and shouldn't be applied to
    a production box, but I think it is ok for testing.

> --
> Christian "naddy" Weisgerber
>                          naddy at mips.inka.de
> 
> _______________________________________________
> freebsd-net at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to
> "freebsd-net-unsubscribe at freebsd.org"
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 4kmcl.patch
Type: text/x-patch
Size: 1802 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-net/attachments/20140209/27c6139e/attachment.bin>


More information about the freebsd-net mailing list