Greetings.

In regard to the NFS Docs below is a rough installation procedure for NFS Server. The cockpit NFS should come later this week.

While creating this rough installation guide I think it would be easier to update the doc site instead of cut and pasting it several times into email. We can just send out emails saying they are updates. There might be a mechanism in place on the docs web site that does it already.  I have no problem doing it that way so long i have access to update the docs page. Let me know.

Here's the rough out line for NFS server from command line.

--------------------------------

NFS Server Install

Network File Server, or NFS for short, is a client and server file system.


NFS versions

NFSv2 - 32 bit files sizes and offsets, udp, no longer used.

NFSv3 - 64 bit files sizes and offsets, improved write performance, supports asynchronous, requires rpcbind to be running.

NFSv4 - no longer requires rpcbind, performance improvements, security improvements, introduces stateful protocol

4.1 - added support for clustered server deployments, added ability for scalable parallel access, multipathing, pNFS.

4.2 - server side improvements (server side clone and copy), security updates, added features ti pNFS.


Recommend NFSv4.x as it only requires UDP or TCP port 2049 to be open. This makes it easier when needing to connect through a firewall.


Planning:

Make sure to have a static hostname and IP set for the NFS server.

*Note

A static IP isn't required but the DHCP server should have the ability to update DNS or connectivity issues will happen. It's preferred to set a static hostname and IP.


It's recommended to use a separate disk or file system for shares. This will ensure that you don't fill up your Operating System file systems.


Installing:

Config Files:

Most Used

  /etc/nfs.conf

  /etc/exports

Others

  /etc/exports.d

  /etc/gssproxy/24-nfs-server.conf

  /etc/modprobe.d/lockd.conf

  /etc/nfsmount.conf

  /etc/request-key.d/id_resolver.conf


Steps to Install

1. Make sure the OS is up to date. (reboot if necessary before continuing on)

    sudo dnf update


2. Install the software needed.

    sudo dnf install nfs-utils


3. Start the server.

    sudo systemctl enable nfs-server --now


4. Confirm its running.

    sudo systemctl status nfs-server


5. Make sure to add the appropriate services/ports to the firewall.

    This one is needed for all NFS versions.

      sudo firewall-cmd --add-service=nfs

   These are needed to support NFSv3.

      sudo firewall-cmd --add-service=mountd

      sudo firewall-cmd --add-service=rpc-bind

    Save the firewall configuration so it persistent across reboots.

      sudo firewall-cmd --runtime-to-permanent


6. Setup a directory to share.

    mkdir /share/share1

    chmod -R 755 /share/share1


7. Add the directory to /etc/exports This is were you setup the share for access and any options you want to use.

    sudo vi /etc/exports # any editor will do

Example:

    /share/share1 client.example.com(rw,no_root_squash)

*Note* The /etc/exports file has a specific format.

    <export> <host><options>

8. After updating /etc/exports run the exportfs to make it available.

    exportfs -av

      # -a export or unexport all directories

     # -v verbose


9. To display the epxorts run exportfs with a different option.

    exportfs -s


Server is ready. Now setup the client.


1. Make sure the OS is up to date. (reboot if necessary before continuing on)

    sudo dnf update


2. Install the software needed.

    sudo dnf install nfs-utils


3. See if the sever can mount it. (If using NFSv3 you can showmount -e nfsserver.example.com but it requires rpcbind)

    mount -t nfs nfsserver.example.com:/share/share1 /mnt

    *If the command comes back with no errors its mounted.

    *You can check by running mount with no options.

    mount

    cd /mnt

    touch file

    # ls

    file

4. You can see the mount options with just by running mount.

   mount | grep mnt

nfsserver.example.com:/share/share1 on /mnt type nfs4 (rw,relatime,vers=4.2,rsize=262144,wsize=262144,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.0.0.1,local_lock=none,addr=10.0.0.2)

*Note* When Fedora Server is the NFS server it defaults to NFSv4.2.