Install the required packages (Ubuntu 12.04):
apt-get install nfs-kernel-server portmap
Open the exports file:
vim /etc/exports
Add the following line:
/home/proudlygeek localhost(insecure,rw,sync,no_subtree_check)
Restart NFS Service:
service nfs-kernel-server restart
or just export the FS:
exportfs -a
Install the client:
apt-get install nfs-common portmap
Make a mount folder:
mkdir /mnt/nfs-share
Setup an SSH tunnel (local-to-remote port):
ssh -fNv -L 3049:localhost:2049 user@hostname
Mount the folder:
mount -t nfs -o port=3049 localhost:/home/proudlygeek /mnt/nfs-share
Alternatively, you could use autossh to keep the port forwarding alive.
autossh -M <monitor_SSH_port> -N -L <your_local_port>:localhost:2049 <remote_server_user>@<remote_server> -f
mount -t nfs -o port=<your_local_port> localhost:/home/proudlygeek /mnt/nfs-share