External Data Representation
- 1 min read
- 2 chapters
Related on Lably
Through Computer network, Operating system and User interface
XDR uses a base unit of 4 bytes, serialized in big-endian order; smaller data types still occupy four bytes each after encoding. Variable-length types such as string and opaque are padded to a total divisible by four bytes. Floating-point numbers are represented in IEEE 754 format.
History
XDR was developed in the mid 1980s at Sun Microsystems, and first widely published in 1987. XDR became an IETF standard in 1995.
The XDR data format is in use by many systems, including:
- Network File System (protocol)
- ZFS File System
- NDMP Network Data Management Protocol
- Open Network Computing Remote Procedure Call
- Legato NetWorker backup software (later sold by EMC)
- NetCDF (a scientific data format)
- The R language and environment for statistical computing
- The HTTP-NG Binary Wire Protocol
- The SpiderMonkey JavaScript engine, to serialize/deserialize compiled JavaScript code
- The Ganglia distributed monitoring system
- The sFlow network monitoring standard
- The libvirt virtualization library, API and UI
- The Firebird (database server) for Remote Binary Wire Protocol
- Stellar Payment Network
Sign in to keep reading
One more chapter is free with a Lably account.
XDR data types
- boolean
- int – 32-bit integer
- unsigned int – unsigned 32-bit integer
- hyper – 64-bit integer
- unsigned hyper – unsigned 64-bit integer
- IEEE float
- IEEE double
- quadruple (new in RFC1832)
- enumeration
- structure
- string
- fixed length array
- variable length array
- union – discriminated union
- fixed length opaque data
- variable length opaque data
- void – zero byte quantity
- optional – optional data is notated similarly to C pointers, but is represented as the data type "pointed to" with a Boolean "present or not" flag. Semantically this is option type.

