| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
NFS Data Storage and Data Types, and the External Data Representation (XDR) Standard (Page 1 of 2) The overall idea behind NFS is to allow someone on one computer to read from or write to a file on another computer as readily as they do on a local machine. Of course, the files on your local machine are all stored in the same file system, using the same file structure and the same means of representing different types of data. You can't be sure that this will be the case when accessing a remote device, and this creates a bit of a Tower of Babel problem that NFS has to deal with. One approach to representation consistency would be to simply restrict access only to remote files on machines that use the same operating system. However, this would remove much of the effectiveness of NFS. It would also be highly impractical to require every computer to understand the internal representation of every other one. A more general method was needed to allow even very dissimilar machines to share data. To this end, the creators of NFS defined it so that it deals with data using a universal data description language. This language is called the External Data Representation (XDR) standard, and was originally described in RFC 1014; it was updated in RFC 1832, XDR: External Data Representation Standard, in 1995. The idea behind XDR is simple, and can be easily understood in the form of an analogy. If you had delegates speaking 50 different languages at a convention, they would have a hard time communicating. You could hire translators to facilitate, but you'd never find translators to handle all the different possible combinations of languages. A more practical solution is to declare one language, such as English, to be a common language. You then only need 49 translators: one to translate from English to each of the non-English languages and back again. To translate from Swedish to Portuguese, you translate from Swedish to English and then from English to Portuguese. The common language could be French, or Spanish, or something else, as long as a translator could be found from all the other languages to that common language. XDR works in the same manner. When information about how to access a file is to be transferred from device A to device B, device A first converts it from A's internal representation to the XDR representation of those data types. The information is transmitted across the network using XDR encoding. Then, device B translates from XDR back to its own internal representation, so it can be presented to the user as if it were on the local file system. Each device needs to know only how to convert from its own language to XDR and back again; device A doesn't need to know device B's internal details and vice-versa. This sort of translation is of course a classic job of the presentation layer, which is where XDR resides in the OSI Reference Model. XDR is itself based on an ISO standard called the Abstract Syntax Notation. Incidentally, the idea described here is also used in other protocols to allow the exchange of data independent of the nature of the underlying systems. For example, a similar idea is behind the way management information is exchanged using the Simple Network Management Protocol (SNMP). The same basic idea underlies the important Network Virtual Terminal (NVT) paradigm used in the Telnet protocol.
Home - Table Of Contents - Contact Us The TCP/IP Guide (http://www.TCPIPGuide.com) Version 3.0 - Version Date: September 20, 2005 © Copyright 2001-2005 Charles M. Kozierok. All Rights Reserved. Not responsible for any loss resulting from the use of this site. |