Skip to content

Latest commit

 

History

History
53 lines (36 loc) · 973 Bytes

nfs-server-setup.md

File metadata and controls

53 lines (36 loc) · 973 Bytes

Steps for NFS Server Setup (Ubuntu Server 22.04.05 LTS)

Package installation

  • Install NFS Server
sudo apt install -y nfs-kernel-server
  • Start NFS Server
sudo systemctl start nfs-kernel-server.server
  • Look at NFS Server Status
sudo systemctl status nfs-kernel-server.server

Configuration

  • Edit /etc/exports file like this (replace the ip range or the directory as you wish)
/acme-data   192.169.1.25(rw,sync,no_subtree_check,no_root_squash)
  • Create the directory mentioned in /etc/exports and adjust its permissions
sudo mkdir /acme-data
sudo chown nobody:nogroup /acme-data
sudo chmod -R 777 /acme-data
  • Apply the config via:
sudo exportfs -a (ou -rav)
  • Check the status of the NFS Server if everything is ok

  • If you have a firewall enabled, you need to allow NFS traffic:

sudo ufw allow from <client_ip> to any port nfs
sudo ufw enable
sudo ufw status