NFS and shared folders problem

Sebastian M=?ISO-8859-1?B?/A==?=sch sebastian at sebastian-muesch.de
Mon Aug 15 12:49:31 UTC 2005


Hi,

Once upon a time Inhabitant of Zion wrote:

> I am sure you should be able to share a folder over both nfs and samba? Right?

As Linux imho uses exclusive locking everywhere, their should be no problem,
right.

> ...

=> You want to share a directory on one host, that all the others can access
without authentification?

1. What type of nfs-server? kernel or userspace?
2. Give us a snapshot of your /etc/exports on the server.
3. Give us a snapshot of your /etc/hosts.allow, /etc/hosts.deny.

Ad 1: If you use the userspace nfs-server, try the kernel one and vice
versa.

Ad 2: Your exports should contain a line like this
---------------------------------------------------
/home   10.0.1.0/24(rw,sync,insecure)
---------------------------------------------------
10.0.1.0/24     allows any connection from a host in
                the range from 10.0.1.1 to 10.0.1.254.

rw              Read/Write access

insecure        Allows connections from ports > 1023
                (If you are connecting as a normal user
                this must be set, as a normal user can't
                use ports < 1024, only root can do this)

Ad 3: Your /etc/hosts.deny this ones:
---------------------------------------------------
portmap:ALL
lockd:ALL
mountd:ALL
rquotad:ALL
statd:ALL
---------------------------------------------------
Deny access to this services from any host ...

And your /etc/hosts.allow needs at least this lines:
---------------------------------------------------
portmap: 10.0.1.0/24 EXCEPT 10.0.1.1
lockd: 10.0.1.0/24 EXCEPT 10.0.1.1
rquotad: 10.0.1.0/24 EXCEPT 10.0.1.1
mountd: 10.0.1.0/24 EXCEPT 10.0.1.1
statd: 10.0.1.0/24 EXCEPT 10.0.1.1
---------------------------------------------------
... but allow All hosts from 10.0.1.0/24 except 10.0.1.1
(my router) to access.

BTW: A info at last. Apart from samba which translate the uid and gid of the
users based on the logins, nfs doesn't. If you access a directory where your
current uid has no access, you won't get access by login. Apart from that,
you can map specific login-uids to specific local uids within the config,
just give "man exports" a try ;-)

Cu
Sebastian

-- 
        .:'
     _ :'_
   .`_`-'_`.     Sebastian Müsch
  :__|\ /|__:      sebastian at sebastian-muesch.de
  :__| S |__:
  :__|   |__:     iTunes ist aus :-(
   `._.-._.'






More information about the ubuntu-users mailing list