Add the folloing to both boxes in the file /etc/networking/interfaces
BOX 1
auto eth0:1
iface eth0 inet static
address 10.0.0.1
netmask 255.255.255.0
BOX 2
auto eth0:1
iface eth0 inet static
address 10.0.0.2
netmask 255.255.255.0
then restart networking with:
sudo /etc/init.d/networking restat
then use the 10.0.0.IPs to use NFS
so on the NFS side you want to share from:
FILE /etc/exports
/pat/to/shared/dir 10.0.0.2(rw,no_root_squash,async,subtree_check)
FILE /etc/hosts.allow
portmap: 10.0.0.2
lockd: 10.0.0.2
rquotad: 10.0.0.2
mountd: 10.0.0.2
statd: 10.0.0.2
then restart the nfs-kernel-server using
sudo /etc/init.d/nfs-kernel-server
then on your box you want to mount the shared drive to:
FILE /etc/fstab
10.0.0.1://path/to/shared/dir /path/to/mount/to nfs
then mount it with:
sudo mount -a