Can not read from ZFS exported over NFSv4 but write to it

Rick Macklem rmacklem at uoguelph.ca
Fri Oct 26 21:30:48 UTC 2012


Yamagi Burmeister wrote:
> On Fri, 26 Oct 2012 15:15:08 -0700
> YongHyeon PYUN <pyunyh at gmail.com> wrote:
> 
> > On Fri, Oct 26, 2012 at 08:07:27AM +0200, Yamagi Burmeister wrote:
> > > On Fri, 26 Oct 2012 10:38:47 -0700
> > > YongHyeon PYUN <pyunyh at gmail.com> wrote:
> > >
> > > > Thanks the info.
> > > > Would you try attached patch?
> > >
> > > Still the same problem. With TSO enabled, the NFS4 mount
> > > stalls when writing to it. Without it works as aspected.
> >
> > I have no longer access to age(4) controller so it's hard to verify
> > the issue on my box.
> > Can you post an URL for captured packets on both sender(age(4)) and
> > receiver side with tcpdump?
> 
> http://deponie.yamagi.org/freebsd/misc/age0_pcap.tar.xz
> 
> sender_age0.pcap is the age0 device on the NFS4 server.
> receiver_em0.pcap is a em0 NIC on the NFS4 client.
> 
> Those files were created by:
> 1. Mount the NFS4 export on the client
> 2. Try to copy a file onto it.
> 3. Forcefully unmount the NFS4 export on the client
> 
I took a look at the packet traces and all that seems to be on them are
a couple of OPEN attempts which reply NFS4ERR_GRACE. This is normal.
After starting an NFSv4 server, it remains in a Grace period (where it
will only handle lock state recovery operations) for greater than a
lease duration. After the lease duration (2 minutes for a FreeBSD
server), it will allow other operations like non-reclaim OPENs.

I'd suggest you wait at least 2 minutes after doing the mount, before
you try to do a file copy (or wait several minutes after starting the
first file copy before assuming it is hung). Once Grace is over, the
server will no longer reply NFS4ERR_GRACE until it is rebooted.

If you capture packets again, but wait 5 minutes before doing the
"umount -f", we should be able to see what is going on.

rick

> --
> Homepage: www.yamagi.org
> XMPP: yamagi at yamagi.org
> GnuPG/GPG: 0xEFBCCBCB


More information about the freebsd-fs mailing list