LinuxQuestions.org
Register a domain and help support LQ
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 06-25-2013, 06:12 AM   #1
ali.abry
Member
 
Registered: Feb 2013
Posts: 74

Rep: Reputation: Disabled
confused over nfs permissions


Hi every body

I just setuped a simple nfs with this entry in exports file on debian 7 :
Code:
/var/www/test 172.16.134.1(rw)
and here is the permisson on /var/www/test file :

Code:
# stat /var/www/test/
  File: `/var/www/test/'
  Size: 4096      	Blocks: 8          IO Block: 4096   directory
Device: fe00h/65024d	Inode: 131888      Links: 4
Access: (0705/drwx---r-x)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2013-06-25 04:34:13.684871311 -0400
Modify: 2013-06-25 04:28:34.852884273 -0400
Change: 2013-06-25 04:34:08.868883967 -0400
 Birth: -
but when i mount the nfs share on client system i don't have write permission but i set "rw" in exports file , shouldn't i have write permission ?
when i change permission on /var/www/test to 707 i have write permission , so whats the use of "rw" or "ro" in exports file ?
 
Old 06-25-2013, 09:48 AM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,396
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
The exports file defines what permissions are granted to the NFS client(s). Granting write permission to clients cannot override the basic file permissions that are built into the server filesystem. OTOH, the NFS server can revoke permissions that might otherwise have been permissible at the filesystem level.
--- rod.
 
Old 06-25-2013, 09:54 AM   #3
camorri
LQ Guru
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1, 14.2
Posts: 5,118

Rep: Reputation: 494Reputation: 494Reputation: 494Reputation: 494Reputation: 494
Quote:
when i change permission on /var/www/test to 707 i have write permission , so whats the use of "rw" or "ro" in exports file ?
This is working as designed. There are two tiers of read write permissions here. The owner of the directory has ultimate control. So, to get write permission, you need both set to allow writing.

Samba file sharing is the same. Think of the situation where the owner of some directory wants 'others' to be able to read files in this directory, but does not want them altered. Does the sys admin know that? Sys admins don't always know all the details about shares, so the owner has ultimate control.
 
  


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
Confused about Linux permissions on a Windows share jsteel Linux - General 5 03-31-2011 12:18 PM
Getting confused with the linux nfs versions? kingston Linux - Newbie 1 07-20-2009 08:24 AM
How to setup proper permissions has me confused Brandon.Wamboldt Linux - Server 1 05-25-2009 12:51 AM
Pretty confused about using numbers for file permissions Squall Linux - General 3 04-21-2004 10:17 PM
I'm confused - Crontab and Access Permissions Newman_SCO Linux - Newbie 5 09-03-2003 09:28 PM


All times are GMT -5. The time now is 11:08 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