Show Table of Contents
8.8. Configuring nfsexport and nfsserver Resources
This section describes the issues and considerations to take into account when configuring an
nfsexport or an nfsserver resource.
The
nfsexport resource agent works with NFSv2 and NFSv3 clients. When using nfsexport, you must do the following:
- Ensure that
nfsandnfslockare enabled at boot. - Add
RPCNFSDARGS="-N 4"to the/etc/sysconfig/nfsfile on all cluster nodes. The"-N 4"option prevents NFSv4 clients from being able to connect to the server. - Add
STATDARG="-H /usr/sbin/clunfslock"to the/etc/sysconfig/nfsfile on all cluster nodes. - Add
nfslock="1"to theservicecomponent in thecluster.conffile. - Structure your service as follows:
<service nfslock="1" ... > <fs name="myfs" ... > <nfsexport name="exports"> <nfsclient ref="client1" /> <nfsclient ref="client2" /> ... </nfsexport> </fs> <ip address="10.1.1.2" /> ... </service>
The
nfsserver resource agent works with NFSv3 and NFSv4 clients. When using nfsserver, you must do the following:
- Ensure that
nfsandnfslockare disabled at boot - Ensure that
nfslock="1"is not set for the service. - Structure your service as follows:
<service ... > <fs name="myfs" ... > <nfsserver name="server"> <nfsclient ref="client1" /> <nfsclient ref="client2" /> <ip address="10.1.1.2" /> ... </nfsserver> </fs> ... </service>
When configuring a system to use the
nfsserver resource agent for use with NFSv3 and NFSv4, you must account for the following limitations:
- Configure only one
nfsserverresource per cluster. If you require more, you must use restricted failover domains to ensure that the two services in question can never start on the same host. - Do not reference a globally-configured
nfsserverresource in more than one service. - Do not mix old-style NFS services with the new
nfsserverin the same cluster. Older NFS services required the NFS daemons to be running;nfsserverrequires the daemons to be stopped when the service is started. - When using multiple file systems, you will be unable to use inheritance for the exports; thus reuse of
nfsclientresources in services with multiple file systems is limited. You may, however, explicitly define target and path attributes for as manynfsclientsas you like.

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.