Path: utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!uunet!maverick.ksu.ksu.edu!wagner From: wagner@iti.org (Larry Wagner) Newsgroups: comp.unix.msdos Subject: Re: PC-NFS and symbolic links (Corrected response) Message-ID: <1991Jan15.145437.23886@maverick.ksu.ksu.edu> Date: 15 Jan 91 14:54:37 GMT References: <328@pcad.UUCP> <2607@krafla.rhi.hi.is> <329@pcad.UUCP> <2680@bimacs.BITNET> <1991Jan15.001645.5941@maverick.ksu.ksu.edu> Sender: news@maverick.ksu.ksu.edu (The News Guru) Organization: Kansas State University Lines: 99 This is a corrected version of my response. After I went home last night I realized I had forgotten to mention that the net join command can only join drives to empty directories - LEW yedidya@bimacs.BITNET (Yedidya Israel) writes: >In article vhulzen@freyr.pttrnl.nl (Wilfried van Hulzen) writes: >>john@pcad.UUCP (John Grow) writes: >> >>>(My original posting) >>>> >It seems that Suns PC-NFS (Version 3.0) does not recognize symbolic >>>> >links through the file systems mounted as drive letters. For example, >>>> >if there is an NFS directory /usr/dostools which has the subdirectories: >>>[stuff deleted] >Does it recignize foo -> d:bar where d is another nfs-drive ? PC-NFS cannot follow symbolic links that go across filesystems or above the mount point you specified. For example, if your UNIX directory structure is such: / | | (usr)|-----------|(bin) | | |---------| |-------| joe pete f1 f2 | | |--------| |---------| bin txt bin txt | | | |---| |----| |--------| f1 f2 t1 t2 t1 t2 | | |----| |----| t1a t1a t1a t1a Making the following assumptions: 1) /, /usr, and /bin are all on separate filesystems 2) /usr/joe/bin/f1 is a symbolic link to /bin/f1 3) /usr/joe/txt/t1 is a symbolic link to /usr/pete/txt/t1 (therefore /usr/joe/txt/t1/t1a ==> /usr/pete/txt/t1/t1a) (and /usr/joe/txt/t1/t1b ==> /usr/pete/txt/t1/t1b) 4) /usr/joe/txt/t2 is a symbolic link to ../../pete/txt/t2 5) /usr and /bin are exported filesystems Now assuming you have made the following PC-NFS mounts: 1) drive D: corresponds to /usr 2) drive E: corresponds to /usr/joe 3) drive F: corresponds to /usr/pete/txt/t1 <<<-- correction made here - LEW 4) drive G: corresponds to /bin The following conditions will arise on the PC with respect to the 3 symbolic links: 1) The link for /usr/joe/bin/f1 WILL NOT appear under drive D: or E: since this link crosses a filesystem boundary. 2) The link for /usr/joe/txt/t1 WILL NOT appear under drive D: or E: since this link crosses a filesystem boundary. This is so even for drive D: because the link uses an absolute path which of course includes the root (/) filesystem. 3) The link for /usr/joe/txt/t2 WILL appear under drive D: but WILL NOT appear under drive E: This is so because the relative path used in the link does not go above the mount point for drive D: (/usr) but does for drive E: (/usr/joe). >>>> Other changes begin here - LEW <<<<< If the net join command is used, the directory link from /usr/joe/txt/t1 to /usr/pete/txt/t1 CANNOT be duplicated (The symbolic directory name exists and is not an empty directory, even though you cannot see it on the PC's directory listing). However, a symbolic link to a directory CAN be simulated by using the PC-NFS net join command by performing the following steps: 1) mkdir E:\txt\mnt # this creates an empty dir (/usr/joe/txt/mnt) to join another PC-NFS drive to # (The net join command only works with an empty directory which # /usr/joe/txt/t1 or E:\txt\t1 is not) 2)net join E:\txt\mnt F: # join drive F: at this mount point # therefore /usr/joe/txt/mnt/ta ==> /usr/pete/txt/t1/t1a # and /usr/joe/txt/mnt/t1b ==> /usr/pete/txt/t1/t1b These examples are what I would expect from my experiences with PC-NFS and symbolic links on our fileserver (I have not tested the exact example provided above - HAVE NOW!! - LEW). I have emulated (not duplicated) symbolic links to subdirectories in the manner presented above but do not know of a way to simulate symbolic links to files. This obviously cannot resolve all of the problems associated with mounting directories with PC-NFS that have symbolic links but it may help in some specific cases. Read the manual about the limitations of the net join command for further information. Note the join command available in later versions of DOS does not work on networked drives. I hope this helps clear up some of the confusion about PC-NFS and symbolic links (provided I haven't made anymore mistakes in my posting). -- -------------------------------------------------------------------------------- Larry E. Wagner | wagner@chepil.weru.ksu.edu USDA-ARS Wind Erosion Research Unit | wagner@matt.ksu.ksu.edu 105B East Waters Hall, KSU | ...!{rutgers,texbell}!ksuvax1!weru!wagner Manhattan, KS 66506 |phone (913)532-6807 --------------------------------------------------------------------------------