help-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ShadowFS (status)


From: Niels Möller
Subject: Re: ShadowFS (status)
Date: 03 Aug 2001 10:36:22 +0200

Marcus Brinkmann <Marcus.Brinkmann@ruhr-uni-bochum.de> writes:

> What you indeed need to take care of are directories in shadowfs, and ports
> to those directories.  Each time someone opens a directory, he will get a
> new port to shadowfs describing the directory (via struct netnode/node)
> and the user/access rights.

An interesting questions is how to handle translators. Should they be
handled as files (i.e. shadowfs returns the real port of a single real
file) or directories (shadowfs constructs a node representing the
union of one or more real directories and returns a port of its own)?
As far as I understand, there is no sharp distinction between files
and directories.

Perhaps the shadowfs should get out of the game and return a real port
as soon as there is a single matching directory? What about these
rules: Shadowfs returns a port to an underlying node whenever either

A. The constructed node would represent the "union" of only one single
   underlying node. So return that underlying node instead.

B. If there are several matching underlying nodes, but there's no
   sensible way to construct a "union". Just return the first (in some
   order) underlying node.

The criteria in B is a little vague. What is intended is nodes that
behave like files rather than directories.

If that is really hard to determine, at lookup or open time, one could
create a union node, respond to directory lookups the shadowfs way,
and respond to read and write requests by forwarding them to the
"first" one of the underlying nodes. But that would make shadowfs a
lot more complex (both to hack and to understand), so it would be nice
if it could be avoided.

Regards,
/Niels



reply via email to

[Prev in Thread] Current Thread [Next in Thread]