Conor Schaefer on 17 Mar 2010 09:35:11 -0700


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Help with NFS Share


On Wed, Mar 17, 2010 at 9:58 AM, Eric H. Johnson <ejohnson@camalytics.com> wrote:
Hi all,

I am trying to map the mythtv (mythbuntu) videos etc. folders to a front
end. In the exports file on the backend I have:

/var/lib/mythtv/videos
*(rw,async,insecure,no_root_squash,no_subtree_check)
/var/lib/mythtv/music   *(rw,async,insecure,no_root_squash,no_subtree_check)
/var/lib/mythtv/pictures
*(rw,async,insecure,no_root_squash,no_subtree_check)
/var/lib/mythtv/recordings
*(rw,async,insecure,no_root_squash,no_subtree_check)

Note: insecure should not be needed, but I get the same thing without it.
There was a reference that it was needed to share with Apple computers
(another UNIX OS).

Both machines are on the same subnet, there is no router, firewall or other
nat device between the two computers.

On the client I enter:

sudo mount 10.0.0.7:/videos /var/lib/mythtv/videos

The client side error reported is:
mount.nfs: access denied by server while mounting 10.0.0.7:/videos

Syslog on the server gives a related error:
Mythtv1-backend1 mountd[2751]: refused mount request from 10.0.0.2 for
/videos (/): not exported

It seems the server is set up reasonably correctly, because I can attach to,
map a drive to, etc. the exports through windows file manager. I also set
the permissions for the folder on both the client and server to match (775).
Additionally localhost is defined in the hosts file for both the client and
server.

Any ideas?
I won't bore you by chastising you for using NFS instead of Samba, but I do recommend you switch. I recently did and the security is much better! Basically, NFS authorization is generally done by manually specifying IP addresses within the exports file.

So, you want something like this in your exports file:

/path/to/shared/dir 10.0.0.22(rw,sync,no_subtree_check)

Then, in /etc/fstab for the host located at, for example, 10.0.0.22, you want a line such as:

10.0.0.11:/path/to/shared/dir /mntpoint nfs rsize=8192,wsize=8192,timeo=14,intr

Assuming, of course, that 10.0.0.11 is the IP address of the server.

Then, on the server, restart NFS (on my Ubuntu server, it's "sudo /etc/init.d/nfs-kernel-server restart" I believe). Then, on the client, a "sudo mount -av" should get the share mounted, and if not, print messages to help you diagnose the problem.

Thanks,
Eric

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug