Tuesday, July 28, 2009

Common NFS Error

Recently while trying to connect to an NFS share I got a familiar error message:


mount: wrong fs type, bad option, bad superblock on Machine:/path,
missing codepage or helper program, or other error
(for several filesystems (e.g. nfs, cifs) you might
need a /sbin/mount.helper program)
In some cases useful info is found in syslog - try
dmesg | tail or so

I checked the usual configuration files to verify that I had the necessary permissions:


/etc/exports <- client should be allowed here with necessary access rights (r,w,rw etc)

/etc/hosts.allow

/etc/hosts.deny <- client should not be listed here.


All the configuration files were valid. The solution to the problem was to install nfs-common:


sudo apt-get install nfs-common
The nfs share can be mounted with:


sudo mount server_name:/path/to/remote/share local_mount_dir


eg.

sudo mount Harry_Hardcore:/home/harry/share /home/user/share

Enjoy! :)

No comments: