set up nfs mounts on freebsd for ubuntu - a 30 sec checklist

chris (2006-05-23 14:12:06)
0 replies
Here is a 30-second checklist for setting up an NFS mount between a freebsd server and an ubuntu system.

First run the following commands on the freebsd system:
sudo portmap
sudo nfsd -u -t -n 1
sudo mountd -r

Note that on systems newer than freebsd version 4, portmap should be replaced with rpcbind.

The /etc/exports looks like this:
# note that mountd must be reloaded if this file is edited.
# use kill -HUP `cat /var/run/`

/home/clacy/dev -maproot=root # (yes I work for yahoo!)

on the remote system (client) first I installed the nfs-common package and then check the available exports like this:
chris@laptop-hostname:~/dev$ sudo apt-get install nfs-common
chris@laptop-hostname:~/dev$ showmount -e
Export list for

so now I can just mount the 'dev' node into my local tree like this:
sudo mount /home/chris/dev

That's it. Using NFS in this way allows me to mount parts of a remove filesystem into my local machine. This is useful in my work situation where I run a headless freebsd dev box onto which cvs is checked out - I can now mount that remote tree into my local tree and then edit any of those files with all the goodness of GNOME and the editor-fu of gedit or eclipse. NFS does come with potential security issues, however, so be sure to manage your hosts files with care.

So that's all.. NFS in 30 seconds