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

Re: NFS share: cannot write



Clive Menzies wrote:

On (13/09/03 01:32), Joan Tur wrote:
Hallo!

I've set up an NFS share (server runs Woody), and I can mount it from the
allowed computer, but I cannot write to it from the client  8-?

Here are the configs:
Server:
- -----
quiniserver:/# cat /etc/exports
# /etc/exports: the access control list for filesystems which may be exported
#               to NFS clients.  See exports(5).
/Dades quinipt(rw)
- -----

Client (from /etc/fstab):
- -----
quiniserver:/Dades      /Dades  nfs     rw,hard,intr    0 0
- -----

No idea on what's going on  8-/


You need to set up access by IP address within /etc/hosts.allow
and /etc/hosts.deny

There is quite a good nfs HOWTO within the Debian docs on your system
which explains how to set it up.
On my system it's at:
file:/usr/share/doc/HOWTO/en-txt/NFS-HOWTO.gz

I'm pretty sure if they are able to mount the nfs filesystem, they aren't dealing with a hosts.* issue. That should show up with a 'failed to mount' message. The NFS-HOWTO may have already helped them find their answer though, especially section 7.4.

Joan, you say you can mount the partition, but you cannot write to it. Are you able to read the contents of files or directories? I think you are dealing with file permission issues. Your user id on the local system may be 1000, and on the nfs server it may be 1022, even though your username is 'joan' on both machines. This may seem a little nieve but the file access is based on the number, and not the name. That is why services like NIS generally go hand-in-hand with NFS. Section 7.4 in the HOWTO Clive pointed out makes quick references to keeping usernames in sync. What it means is keeping the user id to user name mappings in sync across the client systems and the NFS server. Some people will use ldap or another 'database' method of user authentication and id mapping through the PAM system. I guess rsync could be another way to keep them in sync.

For a small group of users, it may be acceptable for the administrator to just specify the user id when you create accounts on each system. As long as joan == 1000 on all systems, NFS based file permissions will work pretty much the same way they work on your local file system with the exception of the root_squash and all_squash option cases. Any file permission issues you still have outside of those two exceptions once you get your user id's to be the same on the client and server are file permission issues you would have on a local unix file system.

Jacob



Reply to: