Re: Proposal: int (permission*)(struct dentry *, int)

From: Roman V. Shaposhnick (vugluskr@unicorn.math.spbu.ru)
Date: Tue May 16 2000 - 03:25:41 EST


On Mon, May 15, 2000 at 01:01:54PM -0700, Linus Torvalds wrote:
>
>
> On Mon, 15 May 2000, Alan Cox wrote:
> > > In summary: filehandles are useful at the protocol level, but it's
> > > good for clients to retain pathnames if they need to recover
> > > filehandles.
> >
> > How do you know the recovered pathname is the same file ?
>
> Don't expect UNIX semantics from a networked filesystem.
>
> Instead, expect _sane_ semantics. The same way you have to do magic things
> for NFS locking if you're a mail client that wants to handle atomicity, a
> networked filesystem doesn't have to try to maintain exact UNIX behaviour.
>
> A sane definition of "same file" over a network is, after all, "same
> naming". What more is there?

  Linus, actually, it depends on the definition of the term "same". May be
I'm wrong, but I guess that sometimes we are able to provide "strong
invariants". I mean, if filesystem knows that it has something that will
identify particular file even after reboot, we should provide some
interface for the filesystem to efficiently express this.

  From my point of view, the main problem of the knfsd is that it tries
to do the filesystem's job instead of querying it by something like:
     dentry_to_fhandle
     fhandle_to_dentry

  Separate question is, what knfsd should do if fs does not provide those
operations. Speaking for myself, I would suggest that the best way is
just say that those filesystems are not exportable at all, but there can
be some heuristic to solve this problem more flexible.

Thanks,
Roman.

-
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 : Tue May 23 2000 - 21:00:10 EST