Next: File Handle in Kernel-Space
Up: Interoperability
Previous: File Handle
The Connectathon testsuites revealed several flaws in the NFS
server implementation in the Linux kernel 2.2.9. The test
result from Solaris clients showed that the Solaris NFS
client assumes:
- Files are unstructured streams of uninterpreted bytes.
- If 2 file handles from the same server are identical,
they represent the same file on the server.
- If 2 file handles from the same server are different,
they must represent the different files on the server.
- All the hard links should be represented by the same
file handle
- When a client renames a file within the same file system,
the file handle should be unchanged.
However, two fields in the file handle in the Linux NFS server,
fb_dentry and fb_dirino, make Solaris's assumption untrue.
fb_dentry is for dentry, which is the internal part for the Linux
file system. It determined by pathname. That implies several
things:
- When a pathname is deleted and then created, their dentries
will be the same although they are different files.
- The hard links have different dentries.
- Rename will lead to different dentries.
Those make dentry very unsuitable for file handle.
Even worse, dentry is a memory pointer. That means the file handle
from the Linux NFS server is not persistent. When the server
is rebooted, the file handlers which clients have may become stale
and for the same file the Linux NFS server may return a different
file handle.
Next: File Handle in Kernel-Space
Up: Interoperability
Previous: File Handle
H.J. Lu
1999-08-15