How many lookup calls are needed to resolve a 5-part pathname (for example, /usr/users/jim/code/
xyz.c) for a file that is stored on an NFS server? What is the reason for performing the translation
step-by-step?
What will be an ideal response?
Five lookups, one for each part of the name.
Here are several reasons why pathnames are looked up one part at a time, only the first of those listed is
mentioned in the book (on p. 229):
i) pathnames may cross mount points;
ii) pathnames may contain symbolic links;
iii)pathnames may contain ‘..’;
iv)the syntax of pathnames could be client-specific.
Case (i) requires reference to the client mount tables, and a change in the server to which subsequent lookups
are dispatched. Case (ii) cannot be determined by the client. Case (iii) requires a check in the client against the
‘pseudo-root’ of the client process making the request to make sure that the path doesn’t go above the pseudo
root. Case (iv) requires parsing of the name at the client (not in itself a bar to multi-part lookups, since the
parsed name could be passed to the server, but the NFSD protocol doesn’t provide for that).
You might also like to view...
A POSIX thread that defers cancellation ________.
a) can be terminated at any point during its execution b) will not be cancelled until it explicitly checks for a cancellation request c) is not notified when a cancellation operation has been requested d) none of the above
What is the best way to prevent RFI?
What will be an ideal response?