LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-03-2009, 07:57 AM   #1
benkenobi
LQ Newbie
 
Registered: Jul 2009
Posts: 3

Rep: Reputation: 0
NFS and group access


Hello,

I found a strange behavior regarding nfs shares with group access rights. I am running a linux server (debian lenny) wich exports the home directories as follows:

# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients. See exports(5).
/export 192.168.3.0/255.255.255.0(ro,sync,insecure,no_subtree_check,fsid=0)
/export/home 192.168.3.0/255.255.255.0(sync,insecure,no_subtree_check,rw,nohide)

Nothing special I think, but:

On directories I am the owner I have rw access as expected

On directories with group access (where I am not he owner but the group has read/write access) I have no access at all (using a debian lenny nfs client, user/group ids on server/workstation are the same)

This behavior changes if I am not member in the groups "davfs2" (GID 116) or "netdev" (GID 110). This means only then I have rw access as expected. I have tried to add this groups on the server side also but without any effect.

Does someone have an idea or has found similar problems?
 
Old 10-04-2009, 12:38 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974
not a networking question, moved to Newbie.
 
Old 10-05-2009, 01:49 AM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,260

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
After you've logged in and failed to access the file; just check with

ls -l file
id

to see what they say.
You could try newgrp http://linux.die.net/man/1/newgrp & see if that helps.
 
Old 10-06-2009, 01:59 AM   #4
benkenobi
LQ Newbie
 
Registered: Jul 2009
Posts: 3

Original Poster
Rep: Reputation: 0
Hello,

thank you for the posts. But I think I wasn't able to explain my problem the right way. And a small hint to the moderator: I dont't think tis is not a networking question because I am no newbie, I am using Linux for several years (since 1996). But let's try again:

As explained in my last post my server is exporting the complete home directory. So all home directories of the users are exported to my local network.
There is no problem to access my own home directory (I am the owner - of course - and user id ist the same on server and client).
The problem occurs if a directory is exported where the group has read/write access (I am NOT the owner but I am a member of the group who has read/write access). In this case I have no access to the directory and all its contents.
If I log in on the server directly (over ssh) access works as expected.
Another way to get this problem is using different distributions on server side and client side.
 
Old 10-06-2009, 03:01 AM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,260

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
Different distro issues could be different versions of nfs; the docs mention v2, v3, v4.
 
Old 10-06-2009, 03:41 AM   #6
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974
NFS - 1 part Network, 2 parts File System. ;-)

NFS uses a network, but it is not networking itself. File permissions, directory listings and such have nothing to do with TCP/IP. Once you have it mounted, the network is no longer relevant at all, unless you're seeing dropouts, delays etc... which you're not.
 
Old 10-07-2009, 01:51 AM   #7
benkenobi
LQ Newbie
 
Registered: Jul 2009
Posts: 3

Original Poster
Rep: Reputation: 0
Hello chrism01,

of course you are right. But in this case I am using debian lenny on server and client side. The nfs version should be nfs4. But as long as I used nfs3 I don't remember such problems.
 
Old 10-07-2009, 06:20 AM   #8
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,260

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
According to this you can specify version num http://www.linuxtopia.org/online_boo...g-options.html on client.
Can't find same option for the server, maybe its supposed to agree with the client if it can; try the verbose option http://linux.die.net/man/8/exportfs
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ls: cannot access /etc/resolv.conf: stale nfs file handle - but i'm not using nfs schneidz Linux - General 4 10-02-2009 03:39 PM
User / Group permissions on NFS shares wayno Linux - General 7 06-24-2007 07:11 AM
How to give access rights to one group to the home-dirs of another group Peter@KKVS Linux - Networking 2 11-09-2006 01:38 AM
NFS group mapping to linux joel112 *BSD 1 02-07-2005 07:09 PM
no access to devices with group access rights flipper333 Debian 2 12-28-2004 10:25 AM


All times are GMT -5. The time now is 08:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration