1.0 Open a file on another node (using RFA) ____ _ ____ __ _______ ____ ______ ____ ********** * fopnxn * ********** NAME: fopnxn -- Open a file on another node (using RFA) SYNOPSIS: NFILE * fopnxn(name, mode, inisiz, recsiz); char *name; /* File to open */ char *mode; /* Open modes */ int inisiz; /* initial size of file */ int recsiz; /* record size for random access files */ DESCRIPTION: Fopnxn() provides the services of fopenx() across DECnet. The usage is the same as fopenx(), with some exceptions: 1. The file name must include a node name and uic. 2. The file pointer returned can only be used with rgetb(), rputb() and rclose(). 3. The remote node must have DECnet object 128 defined as the cooresponding RFA (remote file access) task. 4. On error, both $$ferr and $$nerr should be checked. See the description of fopenx() for more details on the other arguments. Returns NULL on error. $$ferr is set to IE.BAD if the node name or uic are omitted. Actual file errors retuen the FCS error code in $$ferr with the network error code, $$nerr = 1. Network errors will set $$nerr, with the value of $$ferr unpredicatable. The NFILE structure created when a file is successfully openned contains some of the FDB information from the remote file. See stdnet.h for details. Page 2 fopnxn Open a file on another node (using RFA) IMPLEMENTATION DETAILS: Fopnxn() does not set a default uic and device, so they must be specified. It is also safer since the remote system may not have the same device or uic. The RFA object on the remote node does the actual file open or create. On successfull completion of the call, the remote RFA task will have the file open. Don't use fopnxn on non-disk devices, the results are unpredicatable. Note that "no buffer space available" (IE.NBF or E$$NSP) and "invalid lun" (IE.ILU or E$$NOC) may be generated by fopenx() on the remote side and returned. The NFILE pointer returned will only work with rgetb(), rputb() and rclose(). Using is with regular C IO functions will crash the task. Access mode checks are done in this function before the network code is called. BUGS: Only works with RSX FCS. You need to known what your doing.