Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Aug 2020 16:05:02 +0200
From:      Julien Cigar <julien@perdition.city>
To:        Allan Jude <allanjude@freebsd.org>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: nested zfs datasets and NFS4
Message-ID:  <20200818140502.3s4uc6g3r7lagpfp@x1>
In-Reply-To: <06bf3020-a8b1-8754-7a76-a34086fc1e6b@freebsd.org>
References:  <20200818091643.7yur2ix52z7kppea@x1> <06bf3020-a8b1-8754-7a76-a34086fc1e6b@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Aug 18, 2020 at 09:19:45AM -0400, Allan Jude wrote:
> On 2020-08-18 05:16, Julien Cigar wrote:
> > Hello,
> > 
> > With the following configuration (1) I don't understand why do I have
> > access to /usr/jails/j_www1/filer/webapps/phegea as it is not mounted..?
> > I thought that with nested ZFS datasets each dataset should be exported
> > and mounted explicitely ..
> > 
> > (1): https://gist.githubusercontent.com/silenius/2f4e1418d77074d610996b0977776f18/raw/2cb2e5d0bb7ebd9c8e69d6c14245c41051c11bf5/gistfile1.txt
> > 
> > any idea?
> > 
> > Thanks,
> > Julien
> > 
> > 
> 
> Are you using NFSv3 or v4 on the client?

v4 only

> 
> With v4, you can cross mount boundries with a single nfs mount. This is
> very useful for things like NFS mounting homedirs, as you can mount just
> home and have access to each user's personal dataset with out 100s of
> separate mounts on the client.

interesting, I thought it was the opposite. I guess that /etc/exports is
still taken into account when I'd like to mount a nested dataset as
read only for example?

> 
> If you want a child dataset NOT to be reachable, 'zfs set sharenfs=off
> dataset', and it will not be reachable via NFSv4
> 

I don't use sharenfs (I prefer /etc/exports), and it is off by default:

filer1% zfs get sharenfs data/webapps data/webapps/phegea
NAME                 PROPERTY  VALUE     SOURCE
data/webapps         sharenfs  off       default
data/webapps/phegea  sharenfs  off       default

(the reason why I'm not using "sharenfs" is that it was impossible in
the past (don't know if it's still the case) to have multiple export
lines for the same dataset, so it was impossible to export a dataset rw
for somehost and ro for anotherhost)

> -- 
> Allan Jude
> 




-- 
Julien Cigar
Belgian Biodiversity Platform (http://www.biodiversity.be)
PGP fingerprint: EEF9 F697 4B68 D275 7B11  6A25 B2BB 3710 A204 23C0
No trees were killed in the creation of this message.
However, many electrons were terribly inconvenienced.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20200818140502.3s4uc6g3r7lagpfp>