NFS Client Bug

NFS Client Bug

Post by David Hedl » Sat, 18 Nov 1995 04:00:00

: This is in the 1.0.9 kernel and also in the 1.2.13 kernel.  I haven't tried
: any later ones.

: The old Unix trick where you get an invisible temporary file:
:    create a new file
:    open it
:    unlink its name, so it no longer appears in any directories
:    write and read as you please, using the file descriptor that
:      you got when you opened it
:    close it, and it vanishes

: On Linux this works with local disks; but with NFS-mounted directories it
: gives a stale file handle error when you try to write.  Removing the unlink
: call makes the error go away.

: Does anyone have a fix for this?

On other Unixes, this is done using a program called 'biod'. An excerpt from
the (SunOS) manual page:


     When a file that is opened by a client is unlinked  (by  the
     server),  a  file with a name of the form .nfsXXX (where XXX
     is a number) is created by the client.  When the  open  file
     is  closed,  the  .nfsXXX  file  is  removed.  If the client
     crashes before the file can be closed, the .nfsXXX  file  is
     not removed.

     .nfsXXX             client machine pointer to  an  open-but-
                         unlinked file

I don't think there is a Linux equivalent.


 Computer Graphics Group | University of Bristol | UK                      
 *** All opinions expressed are mine and mine alone ***