[425] in Info-AFS_Redistribution

home help back first fref pref prev next nref lref last post

Re: AFS and NeXTs

daemon@ATHENA.MIT.EDU (Craig_Everhart@transarc.com)
Fri Nov 15 10:43:46 1991

Date: Fri, 15 Nov 1991 09:24:52 -0500 (EST)
From: Craig_Everhart@transarc.com
To: Wallace Colyer <wally+@andrew.cmu.edu>, Info-AFS@transarc.com,
Cc: Cal_Thixton@next.com
In-Reply-To: <9111150745.AA24034@ni.umd.edu>

Thanks for the info about how /Net works, that is, with a symlink in
/Net with the sticky bit on.

AFS clearly uses an adapted symlink technology to represent mount
points, but the content of an AFS mount point (that you might get with
readlink(2)) isn't the same as a symbolic link to another file.  Thus,
AFS doesn't currently represent mount points as ordinary symbolic links,
that lstat() doesn't follow but that readlink(2) always interprets
correctly.  Instead, both stat() and lstat() follow the mount point, and
if you want to do the equivalent to lstat() for an AFS mount point, you
have to use the VIOC_AFS_STAT_MT_PT pioctl().

In particular, there are programs out there that believe that they know
how to interpret symbolic links, by doing nothing more than readlink(2).
 What does readlink(2) do on a NeXT system on a symlink with the sticky
bit on?

One possible, if questionable, strategy can emerge from all this, and it
goes something like the following.  Leave root.afs alone for non-NeXT
machines.  Make a special root.afs.next volume that's just like root.afs
except all the mount points have the sticky bit on.  Use this as the
root volume for all NeXT machines in a cell.  Alter the CM for the NeXT
platform so that if it gets an lstat() for a file that's really an AFS
mount point with the sticky bit on, it doesn't follow the mount point,
but instead returns information that's made up to suit the case, so that
'ls -F' and the Workspace will both simply print something like
``(automount)''.

Of course, what will the real, live automounter do with such a symbolic link?

At the moment, there's no way to create an AFS mount point with the
sticky bit on.

I don't *think* that it's reasonable for NeXT CMs to interpret lstat()
on any AFS symlink as an automounter-style symlink--or is it?  Should it
behave differently depending on whether the link has been traversed yet
(the target cell and volume is known) or not?  Should it behave
differently if it's a non-cellular mount point, as opposed to a
cross-cell mount point?  Or a mount point to a known cell?

I don't know what the most reasonable answer is, but I'm rather leery of
the consequences of some AFS mount points suddenly really looking like
symbolic links whose readlink(2) contents are meaningless.

		Craig

home help back first fref pref prev next nref lref last post