Andrei POPESCU <andreimpope...@gmail.com> writes:

> Are you sure you're actually using NFSv4? (check 'mount | grep nfs').

Yes I'm sure. It's all host on path type nfs4 and in options also
vers=4.2.

Also the bog standard auto.net these days has code to mount using NFSv4.

> In my experience in order to make NFSv4 work it's necessary to configure 
> a "root" share with fsid=0 or something like that and mount
> the actual shares using a path relative to it (my NFS "server" is 
> currently down, so I can't check exactly what I did).

That's the weirdness I meant. But it's not true, these days and hasn't
been for years. Or maybe it's hidden? But I can do, for example:

# mount zippy:/tmp /mnt/foo  
# mount|grep zip
zippy:/tmp on /mnt/foo type nfs4 
(rw,relatime,vers=4.2,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.0.2.119,local_lock=none,addr=10.0.2.126)

I don't have anything about that in fstab. This is actually a tmpfs
mount where I have fsid=something in /etc/exports but I don't know if
that's required today. zfs mounts the same way from zippy and I don't
have any fsid stuff there. Of course it could be handled automatically.

Autofs mounts a little differently, this is like the old way:

zippy:/ on /net/zippy type nfs4 
(rw,nosuid,nodev,relatime,vers=4.2,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.0.2.119,local_lock=none,addr=10.0.2.126)
zippy:/tmp on /net/zippy/tmp type nfs4 
(rw,nosuid,nodev,relatime,vers=4.2,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.0.2.119,local_lock=none,addr=10.0.2.126)

> As far as I know ZFS is using the kernel NFS server, it's just providing 
> a convenient method to share / unshare so it's not necessary to mess 
> with /etc/exports if all your shares are ZFS data sets.

Good to know.

Reply via email to