Skip to main content
In this lesson you’ll learn to connect to an NFS server, mount a remote export on a client, verify access, and make the mount persistent across reboots so your network storage remains available.
A slide titled "Demo: Working with Network Attached Storage" describing an NFS workflow. On the right are dark rounded buttons listing steps: "Connect to an NFS share", "Mount", "Test access", and "Make it persistent."
By the end of this walkthrough you’ll understand how to extend a system’s storage using NFS, validate the mount, and ensure the export is re-mounted automatically on boot.

Step 1 — Verify connectivity to the NFS server

First, confirm the client can reach the NFS server over the network. Replace the example IP with your server’s address (here: 10.0.2.15).
If ping fails, check routing, firewall rules, or that the NFS server is running and reachable on the expected network.
Network connectivity and appropriate firewall rules (e.g., allowing NFS/RPC ports) are required before mounting. Ensure you have administrative privileges on the client to create mount points and perform mounts.

Step 2 — Create a mount point on the client

Create the directory where the remote export will be mounted. Use -p to avoid errors if the parent exists already.

Step 3 — Mount the NFS share manually (runtime)

Mount the remote export. In this example the server export path is /srv/nfs/share/nfs-lab on host 10.0.2.15.
Validate the mount by checking the list of mounted filesystems for the mount point:
Quick access tests:
The mount command above performs a runtime (ephemeral) mount. It remains until unmounted or the system reboots. To ensure automatic mounting after reboot, add the export to /etc/fstab with appropriate options.

Step 4 — Make the mount persistent by editing /etc/fstab

Add an entry to /etc/fstab so the NFS share is mounted automatically on boot. Common and useful NFS mount options include _netdev, nofail, and vers=. Example /etc/fstab entry (server: 10.0.2.15, export: /srv/nfs/share/nfs-lab, mount point: /mountnfs):
After saving /etc/fstab, apply mounts without rebooting:
Confirm the persistent mount is active:

Common NFS mount options

Step 5 — Summary and considerations

  • Use _netdev to avoid attempting to mount network filesystems before network interfaces are up.
  • Use nofail so booting continues when the remote share is unavailable.
  • Force vers= if your server requires a specific NFS protocol version.
  • Adjust rsize/wsize, locking, and security options (sec=) as required by your environment and workload.
  • If you need automount behavior rather than static fstab entries, consider systemd automount units or autofs for on-demand mounting.

References and further reading

This completes the lesson on mounting an NFS share and making the mount persistent across reboots.

Watch Video