PC-NFS and symbolic links

Larry Wagner wagner at iti.org
Tue Jan 15 11:16:45 AEST 1991


yedidya at bimacs.BITNET (Yedidya Israel) writes:

>In article <vhulzen.663527245 at freyr> vhulzen at freyr.pttrnl.nl (Wilfried van Hulzen) writes:
>>john at 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/t1
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).

If the net join command is used, the directory link /usr/pete/t1 can be simulated
using the PC-NFS net join command by entering:

    net join E:\t1 F:

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).  I have emulated
symbolic links to subdirectories in the manner presented above but do not know of a way
to simulate symbolic links to files.  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 didn't make any mistakes in my example).

--
--------------------------------------------------------------------------------
Larry E. Wagner                     | wagner at chepil.weru.ksu.edu
USDA-ARS Wind Erosion Research Unit | wagner at matt.ksu.ksu.edu
105B East Waters Hall, KSU          | ...!{rutgers,texbell}!ksuvax1!weru!wagner
Manhattan, KS 66506                 |phone (913)532-6807
--------------------------------------------------------------------------------



More information about the Comp.unix.msdos mailing list