[comp.unix.sysv386] Files hidden by NFS mounts

ir@cel.co.uk (ian reid) (12/06/90)

Suppose you have a local directory on local machine /usr/me, and that this
directory has files in it.  Now what happens to these files if /usr/me
is used as a mount point for a remote file system.

That is if you unmount the remote file system are the files that were in the 
local directory /usr/me guaranteed to be as they were before.

I am primarily interested in this for ISC 2.2 on a 386 box, when using NFS,
but any discussion for other flavours would be welcome.  RTFM's accepted.
-- 
Ian Reid 					#include <std/disclaimer.h>
UUCP: ir@cel.uucp or ir@cel.co.uk or    ...!{ukc,mcsun,uunet}!cel!ir
"Computers..proof positive that no-one yet understands how to describe any real
 world situation in 0's and 1's."

geoff@dragon.ism.isc.com (Geoffrey Kimbrough) (12/08/90)

In article <7453@suns302.cel.co.uk> ir@cel.co.uk (ian reid) writes:
>
>Suppose you have a local directory on local machine /usr/me, and that this
>directory has files in it.  Now what happens to these files if /usr/me
>is used as a mount point for a remote file system.
	Nothing at all happens to them, except that you can't access them
	until you unmount the filesystem "covering" them.  This is precisely 
	the same thing that would happen if you used /usr/me as a mount point
	for a local filesystem.
>That is if you unmount the remote file system are the files that were in the 
>local directory /usr/me guaranteed to be as they were before.
	Yes, but "Guaranteed" is a strong word.  What gets interesting is that 
	the semantics of NFS don't allow you to cross more than one mount point.
	In the above case, suppose some other machine had your /usr mounted.
	Then users on that system (which could include yourself through rlogin)
	would see the *original* contents of your /usr/me directory, while users
	on your machine could not.  Endless opportunity for practical jokes.
>but any discussion for other flavours would be welcome.  RTFM's accepted.
	Ok, RTFM 8^). I don't know what volume though. I'm pretty sure that any
	flavor that did not behave as above should not be called a UNIX OS.
	The rationale for this restriction is to prevent circular topography,
	like if machine foo mounted bar:/usr/bin on /usr and machine bar
	mounted foo:/usr/bin on /usr.  Now think about letting college students
	do this 8^).  (BTW, RFS works pretty much the same way.)

Geoffrey Kimbrough -- Senior System Therapist
INTERACTIVE Systems Corporation -- A Kodak Company
I think machines and clocks have secret motives, but then again...
Maybe they're made that way.