All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Pocock <daniel@pocock.com.au>
To: linux-nfs@vger.kernel.org
Subject: extremely slow nfs when sync enabled
Date: Sun, 06 May 2012 09:26:01 +0000	[thread overview]
Message-ID: <4FA643A9.3010406@pocock.com.au> (raw)



I've been observing some very slow nfs write performance when the server
has `sync' in /etc/exports

I want to avoid using async, but I have tested it and on my gigabit
network, it gives almost the same speed as if I was on the server
itself. (e.g. 30MB/sec to one disk, or less than 1MB/sec to the same
disk over NFS with `sync')

I'm using Debian 6 with 2.6.38 kernels on client and server, NFSv3

I've also tried a client running Debian 7/Linux 3.2.0 with both NFSv3
and NFSv4, speed is still slow

Looking at iostat on the server, I notice that avgrq-sz = 8 sectors
(4096 bytes) throughout the write operations

I've tried various tests, e.g. dd a large file, or unpack a tarball with
many small files, the iostat output is always the same

Looking at /proc/mounts on the clients, everything looks good, large
wsize, tcp:

rw,relatime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.x.x.x,mountvers=3,mountport=58727,mountproto=udp,local_lock=none,addr=192.x.x.x
0 0

and
 rw,relatime,vers=4,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,port=0,timeo=600,retrans=2,sec=sys,clientaddr=192.x.x.x.,minorversion=0,local_lock=none,addr=192.x.x.x 0 0

and in /proc/fs/nfs/exports on the server, I have sync and wdelay:

/nfs4/daniel
192.168.1.0/24,192.x.x.x(rw,insecure,root_squash,sync,wdelay,no_subtree_check,uuid=aa2a6f37:9cc94eeb:bcbf983c:d6e041d9,sec=1)
/home/daniel
192.168.1.0/24,192.x.x.x(rw,root_squash,sync,wdelay,no_subtree_check,uuid=aa2a6f37:9cc94eeb:bcbf983c:d6e041d9)

Can anyone suggest anything else?  Or is this really the performance hit
of `sync'?



             reply	other threads:[~2012-05-06  9:26 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-06  9:26 Daniel Pocock [this message]
2012-05-06 11:03 ` extremely slow nfs when sync enabled Daniel Pocock
  -- strict thread matches above, loose matches on Subject: below --
2012-05-06  3:00 Daniel Pocock
2012-05-06 18:23 ` Myklebust, Trond
2012-05-06 21:23   ` Daniel Pocock
2012-05-06 21:49     ` Myklebust, Trond
2012-05-06 22:12       ` Daniel Pocock
2012-05-06 22:12       ` Daniel Pocock
2012-05-06 22:42         ` Myklebust, Trond
2012-05-07  9:19           ` Daniel Pocock
2012-05-07 13:59             ` Daniel Pocock
2012-05-07 17:18               ` J. Bruce Fields
2012-05-08 12:06                 ` Daniel Pocock
2012-05-08 12:45                   ` J. Bruce Fields
2012-05-08 13:29                     ` Myklebust, Trond
2012-05-08 13:43                     ` Daniel Pocock

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4FA643A9.3010406@pocock.com.au \
    --to=daniel@pocock.com.au \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.