Re: [NFS] Re: Linux 2.2.16pre5 - NFS?!

From: Neil Brown (neilb@cse.unsw.edu.au)
Date: Wed May 31 2000 - 17:39:37 EST


On Wednesday May 31, dwmw2@infradead.org wrote:
>
> neilb@cse.unsw.edu.au said:
> > On Tuesday May 30, F.vanMaarseveen@inter.NL.net wrote:
> > > - knfsd cannot handle exported subdirs with different permissions
> > > such as "rw" versus "ro" (I believe) unless they are different
> > > [local] mounts on the server.
>
> What's the point? I always thought you could trivially get access to
> anywhere under the mountpoint if you had access to a subdirectory. Is that
> no longer the case with knfsd? Can I export /mountpoint/subdir and know that
> the clients can't actually get into /mountpoint?

Certainly, as long as you don't give the "nosubtree_check" flag.
Without nosubtree_check, knfsd insists on finding each accessed file
in the directory tree, and making sure that the export-point is an
ancestor of the file. There is a cost though - if a file is moved to
a different directory while open, the server may loose track of it,
not be able to find it in the filesystem, and will deny access.

>
> > > - when exporting a locally mounted cdrom it is no longer
> > > possible to umount the cdrom until "exportfs -r" is issued
> > > once it has been mounted over NFS. knfsd keeps it busy.
>
> > These differences have always been there, and aren't about to go away,
> > but aren't really an issue.
>
> The fact that you can't unmount an exported filesystem, and that you have
> to explicitly export it after mounting it, could be fixed by adding extra
> cruft to {u,}mount(8). But it's a userspace issue.
>
> Actually, I'd quite like to fix the 'having to unexport' problem by adding
> timeouts to the kernel's export entries, so you can unmount it if nobody's
> accessed it by NFS in the last <n> seconds. But I've been saying that for
> months, and haven't got round to doing it properly yet. :)

Yes, a number of things can be improved once we get an up-call
mechanism working properly ... I wonder who will get there first:-)

NeilBrown

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Jun 07 2000 - 21:00:12 EST