plash
[Top][All Lists]
Advanced

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

Re: [Plash] Plash 1.9: constructing file namespaces is more flexible


From: Mark Seaborn
Subject: Re: [Plash] Plash 1.9: constructing file namespaces is more flexible
Date: Sun, 10 Jul 2005 16:46:57 +0100 (BST)

David Hopwood <address@hidden> wrote:

> Mark Seaborn wrote:
> > In both Linux and Plan 9, a directory must exist before you can mount
> > another directory at that point to replace it.  This is not the case
> > in Plash.  When you attach an object at "/bin", it adds a "bin" entry
> > to the root directory.  When you then attach an object at "/bin/foo",
> > the directory at "/bin" will be unioned with a "foo" entry.
> 
> Does this override any "foo" entry in the Unix directory mounted at "/bin"?

Yes, it does.

Let's make this clearer by giving names to these objects.  Suppose you
have the structure:

/
 * bin:  attach X
    * foo:  attach Y

In the resulting filesystem, "/bin" will contain a "foo" entry that
maps to Y.  X's "foo" entry will be ignored, even if it's a directory.
This is how the semantics are different from recursive union
directories.  When you attach an object like Y below another object
like X in the tree, Y replaces the corresponding entry in X.  Y will
not get combined with anything in this case (because there is nothing
attached below "/bin/foo" in this tree).

Another example:

/
 * usr:  attach X
    * bin
       * foo:  attach Y

Y will override any "bin/foo" object in X.  Furthermore, if X contains
a "bin" entry that *isn't* a directory, this entry will get overridden
-- in the resulting filesystem, "/usr/bin" would be a directory
containing only "foo".

Mark




reply via email to

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