My question:
>
> Some of my users have troubles with the automounter.
> They do the following:
>
> cd /net/host/.....
> ...
> DIR=`pwd` (or getcwd() in an application)
> ...
> cd anywhere_else
> ...
> open_a_file_in_$DIR
>
> and ... they cannot open the file because DIR contains /tmp_mnt/host/...
> and the filesystem is no longer mounted. DIR should be /net/host/... but
> that's not the way automount works. Is there a solution. Why does automount
> work so. Is it a principle problem that automount cannot mount directly
> at /net/host, or is there another reason?
Answers:
This is a known difficulty with any automounting scheme (amd included).
There's not much to do about it, though several people have scripts or
programs of varying complexity to strip off the leading /tmp_mnt prefix.
If you think through how automount works, and times out mounts, you
realize it must make the actual NFS mount elsewhere, and provide a
symlink to the location (e.g., /net/host -> /tmp_mnt/net/host).
A Number of people gave me suggestions for going around this problem.
A number of scripts they send me for a substitute of "cd" and "getcwd()"
of "getwd()". These routines can be put into libc.so but this only works
in a Sun environment. For others there is no solution.
Thanks to:
ral@cerc.wvu.wvnet.edu
miker@sbcoc.com
etnibsd!vsh@uunet.UU.NET
katkam@fuwutai.att.com
kalli!kevin@fourx.Aus.Sun.COM
mcb@xwin.eng.hou.compaq.com
celita@taux01.nsc.com
bernards@ECN.NL
Dourish@europarc.xerox.com
Gert van Antwerpen.
TNO Institute of Applied Physics.
P.O.Box 155, 2600 AD Delft, The Netherlands.
Phone: +31 15-692000, Fax: +31 15-692111
Email: antwerp@tpd.tno.nl
This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:06:38 CDT