cc [ flag ... ] file ... -lrpcsvc [ library ... ]
#include <rpc/rpc.h> #include <rpcsvc/rstat.h>
enum clnt_stat rstat(char *host, struct statstime *statp);
havedisk(char *host);
MT-Safe
rstat() fills in the statstime structure statp for host. statp must point to an allocated statstime structure. rstat() returns RPC_SUCCESS if it was successful; otherwise a enum clnt_stat is returned which can be displayed using clnt_perrno(3N) .
havedisk() returns 1 if host has disk, 0 if it does not, and -1 if this cannot be determined.
The following XDR routines are available in librpcsvc:
xdr_statstime
xdr_statsvar