Specifications
Remote Procedure Call Programming Guide Page 7
RPC Number Program Description
100020 LOCKPROG local lock manager
100021 NETLOCKPROG network lock manager
100022 X25PROG x.25 inr protocol
100023 STATMON1PROG status monitor 1
100024 STATMON2PROG status monitor 2
100025 SELNLIBPROG selection library
100026 BOOTPARAMPROG boot parameters service
100027 MAZEPROG mazewars game
100028 YPUPDATEPROG yp update
100029 KEYSERVEPROG key server
100030 SECURECMDPROG secure login
100031 NETFWDIPROG nfs net forwarder init
100032 NETFWDTPROG nfs net forwarder trans
100033 SUNLINKMAP_PROG sunlink MAP
100034 NETMONPROG network monitor
100035 DBASEPROG lightweight database
100036 PWDAUTHPROG password authorization
100037 TFSPROG translucent file svc
100038 NSEPROG nse server
100039 NSE_ACTIVATE_PROG nse activate daemon
150001 PCNFSDPROG pc passwd authorization
200000 PYRAMIDLOCKINGPROG Pyramid-locking
200001 PYRAMIDSYS5 Pyramid-sys5
200002 CADDS_IMAGE CV cadds_image
300001 ADT_RFLOCKPROG ADT file locking
2.4. Passing Arbitrary Data Types
In the previous example, the RPC call passes a single unsigned long RPC can handle arbitrary data struc-
tures, regardless of different machines’ byte orders or structure layout conventions, by always converting
them to a network standard called External Data Representation (XDR) before sending them over the wire.
The process of converting from a particular machine representation to XDR format is called serializing, and
the reverse process is called deserializing. The type field parameters of callrpc() and registerrpc() can be a
built-in procedure like xdr_u_long() in the previous example, or a user supplied one. XDR has these built-
in type routines:
xdr_int() xdr_u_int() xdr_enum()
xdr_long() xdr_u_long() xdr_bool()
xdr_short() xdr_u_short() xdr_wrapstring()
xdr_char() xdr_u_char()
Note that the routine xdr_string() exists, but cannot be used with callrpc() and registerrpc(), which only
pass two parameters to their XDR routines. xdr_wrapstring() has only two parameters, and is thus OK. It
calls xdr_string().
As an example of a user-defined type routine, if you wanted to send the structure
struct simple {
int a;
short b;
} simple;