ATTENTION ATTENTION has launched. Visit the shop at Lots of Photo Gear at the moment
ATTENTION ATTENTION is just launched! - Task and project management made easy. Try it for free.

Create your own lists of things to do - arrange the order to do them - move them around - group them

No limitations - all free project management - try the free demo before signing up - demo:
Debian NFS server – Ubuntu NFS client

NFS is a great way to share and get access to files across a network. The NFS system gives the option to mount a NFS from an external system and a local mount point on your locale system.

To get this working, you need two systems – a server and a client.

Installing the NFS Server

I have en Debian server running, where I would like easy access to some of the folders from my workstation. To do this, I will install the nfs-kernel-server and the portmap packages like this:

# aptitute install nfs-kernel-server portmap

The NFS server and the portmap service is now installed and up and running.

Which folders to share

To defined which folder we want to share and to which client, we have to take a look at the /etc/exports file. So open /etc/exports in you favorite editor and insert a line like this:


This tells the NFS service, that I want to share my home folder /home/js to the client at IP with read-write (rw) access.

To reload the defined exports I have to run the exportfs command like this:

# exportfs -a

That’s it – we done here

Access the NFS share from an Ubuntu Client

I am using Ubuntu 10.4 as my primary workstation, so I would like to access my home folder on my server. To do this, I have to install the nfs-common package, so I will select my System menu, goto Administration and click on Synaptic Package Manager. Here I will find the nfs-common package and install it as shown here:
nfs-common in synaptic package manager

All that’s left is to mount the share. I will just enter the share to my fstab file and it will then be ready to mount (and automatically mounted on the startup). Again – use your favorite editor to add a line to the /etc/fstab: /media/serverhome   nfs rw 0 0

This will let the system mount the /home/js share located on the server with the IP, into the local folder /media/serverhome with read-write (rw) access.

When this is done, we must create the folder /media/serverhome on the locale machine and then, either reboot the system or manually mount the share like this:

# mount /media/serverhome

And we are done.

Leave a Reply