Mounting an NFS Folder

Most of this info was pulled from the website Peter Mount’s Blog

First we need to tell NFS to use statd, to do this

sudo /etc/init.d/rpcbind start 
sudo vi /etc/default/nfs-common
add the line "NEED_STATD=yes"
reboot PI or /etc/init.d/nfs-common restart

Next we need to create a local folder that will be the mount point of the remount NFS folder. In this instance I have a folder called ‘raspberry’ on my Netgear RasdyNAS NV+ device

sudo mkdir -p /nas/raspberry
sudo chmod 777 /nas/raspberry

Now we can mount the remote folder to local folder

sudo mount /nas/raspberry

Change the IP address to whatever you NFS server has.

If you subsequently want to remove the remote folder, or unmount it, then using the following command

sudo umount /nas/raspberry

If you want the mount to be available everytime you boot the pi, then you need an entry in /etc/fstab

sudo vi /etc/fstab

And add the following entry at the end of the file: /nas/raspberry nfs defaults 0 0

Thats it. The next time you reboot the pi it will automatically mount that drive.

Your email address will not be published. Required fields are marked *