Subject: Re: Interface to change NFS exports
To: Manuel Bouyer <bouyer@antioche.eu.org>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-kern
Date: 09/11/2005 19:05:33
--uZ3hkaAS1mZxFaxD
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Mon, Sep 12, 2005 at 01:08:07AM +0200, Manuel Bouyer wrote:
> On Sun, Sep 11, 2005 at 01:20:58PM +0200, Julio M. Merino Vidal wrote:
> > Hi everybody,
> >=20
> > while adding NFS support to tmpfs, I found that the current way to
> > change NFS export information is... how could I say it... very ugly.
> > It seems to be a bandaid over what was used in the past to mount
> > FFS systems, which makes it confusing and difficult to extend.
> > (Don't we aim for clean design? ;-)
> >=20
> > [...]
> >=20
> > ftp://ftp.NetBSD.org/pub/NetBSD/misc/jmmv/export.diff
>=20
> Hi,
> while you're at it, could you look at fixing a very long outstanding
> problem ? A /etc/rc.d/mountd reload isn't atomic, there is a window
> in which no filesystems are exported at all, and if a request comes in
> at this time, nfsd replies with a "permission denied".
>=20
> At first glance, we would need to keep 2 export list in kernel and switch
> from one to the other, much like what IPF does with the filters.
Not necessarily.
I think part of the problem is how mountd does things, though to be
honest, I have avoided looking the code. :-) I think if mountd were
changed to build up state then apply it, we could achieve an atomic update
w/o multiple lists in the kernel.
> I don't ask you implement this, but as you're planning to change the
> interface, please think about it in the new one :)
I think all that would be needed would be for there to be a way to upload=
=20
multiple export entries at once. That way we can say, "here, this is the=20
new export list."
I agree that all Julio would need to do now is think about how we add=20
multiple entries at once, and we'd be prepared for this in the future.
Take care,
Bill
--uZ3hkaAS1mZxFaxD
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)
iD8DBQFDJOJsWz+3JHUci9cRAradAKCKHzqU8cBeoQXFXoqPKzjEGiajvwCfYICl
9FL/dzyxOE3rbxLF/D2NqO4=
=QDd3
-----END PGP SIGNATURE-----
--uZ3hkaAS1mZxFaxD--