The z/OS NFS ( Network File System ) Guide and Reference describes in-depth about bringing up and configuring z/OS NFS. But instead of spending hours going through the NFS publications, some have requested a quick setup guide to help get z/OS NFS up and running with minimal time and effort. With the following steps, some are now reporting it takes only minutes to bring up z/OS NFS.
What is z/OS NFS? See our introductory page here.
Basic TCP/IP, RPCBIND, OMVS and RACF services are pre-requisites in order to bring up z/OS NFS.
- Create z/OS NFS Client and Server Log Data Sets.
Two data sets per client and server. These log data sets store the messages for the z/OS NFS start-up
procedures. This log can be used to identify user correctable errors.
E.g. create client log data sets
NFSMSG1 DD DSN=MVSHLQ.NFSTRACE.CLNT1,
DCB=(BLKSIZE=6144,DSORG=PS,LRECL=137,RECFM=VB),
VOL=SER=XXXXXX,SPACE=(TRK,(500)),DISP=(NEW,CATLG)
Repeat for second client log data set MVSHLQ.NFSTRACE.CLNT2
E.g. create server log data sets
NFSLOG1 DD DSN=MVSHLQ.NFSTRACE,
DCB=(BLKSIZE=6144,DSORG=PS,LRECL=137,RECFM=VB),
VOL=SER=XXXXXX,SPACE=(TRK,(500)),DISP=(NEW,CATLG)
Repeat for second server log data set MVSHLQ.NFSTRAC2
- Create 2 KSDS Mount Handle Data Sets for z/OS NFS Server
For z/OS NFS server to maintain a list of the active mount points in a pair of files called the file handle data sets on MVS, also known as the mount handle database (MHDB).
Refer to GFSAMHDJ in the sample library MVSHLQ.NFSSAMP or use the following
E.g. DEFINE CLUSTER (NAME(MVSHLQ.FHDBASE1) -
VOL(XXXXXX) -
CYL(1 1) -
INDEXED -
REUSE -
KEYS(16 0) -
SHAREOPTIONS(1 3) -
RECSZ(1700 2000))
Repeat for second mount handle data set MVSHLQ.FHDBASE2
- Create 2 KSDS Lock Data Sets for z/OS NFS Server
The lock data sets record the client host IP address and, for NFS V4, the client identification as well as the client host name. Following a server outage, the z/OS NFS server reads the lock data sets during initialization to determine which clients can reclaim locks.
Refer to GFSAMHDJ in the sample library MVSHLQ.NFSSAMP or use the following
E.g. DEFINE CLUSTER (NAME(MVSHLQ.LDBASE1) -
VOL(XXXXXX) -
CYL(1 1) -
INDEXED -
REUSE -
KEYS(16 0) -
SHAREOPTIONS(1 3) -
RECSZ(1700 2000))
Repeat for second mount handle data set MVSHLQ.LDBASE2
- Create RACF users for z/OS NFS Server and Client, lock and stat daemon if they do not exist.
E.g.
AU (MVSNFS) OWNER(IBMUSER) OMVS(UID(99000))
AU (MVSNFSC) OWNER(IBMUSER) OMVS(UID(0))
AU (LOCKD) OWNER(IBMUSER) OMVS(UID(0))
AU (STATD) OWNER(IBMUSER) OMVS(UID(0))
- Create z/OS NFS Server Site Attribute and Exports Data Sets.
Refer to GFSAPATT and GFSAPEXP members in the sample library MVSHLQ.NFSSAMP for samples of Site
Attributes and Exports Data Sets respectively. Adjust the values if needed.
- Create z/OS NFS Server Procedure ( e.g. mvsnfs ) and Client Procedure ( e.g. mvsnfsc ) in PROCLIB for starting up server and client.
Refer to GFSAPROC and GFSCPROC members in the sample library MVSHLQ.NFSSAMP for samples of
server and client procedures respectively.
- Server Procedure should point to corresponding Log, Site Attribute, Exports, Mount Handle, and Lock Data Sets created above.
E.g. in sys1.proclib(mvsnfs) server procedure
//NFSLOG1 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.NFSTRAC1
//NFSLOG2 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.NFSTRAC2
//NFSATTR DD DISP=SHR,DSN=&NFSPRFX..CNTL(GFSAPATT)
//EXPORTS DD DISP=SHR,DSN=&NFSPRFX..CNTL(GFSAPEXP)
//FHDBASE DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.FHDBASE1
//FHDBASE2 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.FHDBASE2
//LDBASE DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.LDBASE1
//LDBASE2 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.LDBASE2
- Similarly, z/OS NFS Client Procedure should point to the Client Log Data Sets created above.
E.g. in sys1.proclib(mvsnsc) client procedure
//NFSCMSG1 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.NFSTRACE.CLNT1
//NFSCMSG2 DD DISP=SHR,DSN=&NFSPRFX..MVSHLQ.NFSTRACE.CLNT2
- Start z/OS NFS Server
Assuming the server procedure created above is named mvsnfs in sys1.proclib. Issue mvs command
s mvsnfs
The following message should appear.
GFSA348I z/OS NETWORK FILE SYSTEM SERVER (HDZ222N, HDZ222N) STARTED.
- Starting z/OS NFS Client
Define the z/OS client as a file system in the z/OS UNIX BPXPRMxx member of SYS1.PARMLIB.
E.g. FILESYSTYPE
TYPE(NFS)
ENTRYPOINT(GFSCINIT)
PARM(’biod(8)’)
ASNAME(mvsnfsc)
Start the z/OS UNIX address space, which will cause the BPXPRMxx member to be used. As part of the z/OS UNIX startup, the z/OS NFS client will be started in an z/OS UNIX colony address space.
Wait until this message appears before proceeding:
BPXI004I OMVS INITIALIZATION COMPLETE
The following message should appear when z/OS NFS Client comes up.
GFSC700I z/OS NETWORK FILE SYSTEM CLIENT (HDZ222N) started. OAxxxxx,
GFSC4XAC, Jun 8 2015 16:18:24 .
- Other features
For advanced features, please refer to z/OS NFS Guide and Reference.
For instance, Security topics can be found in Chapter 10 of z/OS NFS Guide and Reference -- Exports Data Sets section, and Configure a Secure z/OS NFS Server section, which describes about RPCSEC_GSS Authentication and Encryption.