Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Under Redhat, if I export a folder as an NFS mount, does the folder have to have RW for users/groups/others? Right now /storage/software is -rwxr-xr-x root/root

i.e. /etc/exportfs

/storage/software *(rw,sync)

On my client, I can mount but I can't write. I'm using a regular user and NOT root. I think "no_root_squash" fixes it but I really don't want that. Then again, nor do I want to have to chmod 777 the folder on the server.

share|improve this question

2 Answers 2

NFS uses the filesystem permissions across systems.

A reasonable solution would to use a group that all users were members of and set the SGID bit on the directory as well. Public writable is for /tmp. If you must, at least set the sticky bit.

share|improve this answer
    
then it looks like I'll have to chmod 777 the folder then. It's just a folder for the developers to store all their files. –  luckytaxi Apr 12 '10 at 14:31
1  
The guy just provided you the solution NOT to do chmod 777. You have to use a group that has writable access on your shared folder. Just create a group on all servers make sure it has the same ID and then SGID it: find /foldername/ -type d -print0|xargs -0 chmod g+rwxs;chmod -R u+rw,g+rw,o-w /foldername/;chgrp -R newgroup /foldername/ –  Mircea Vutcovici Apr 12 '10 at 14:53

You should have the same user IDs and group IDs on both servers. At least those that will use the NFS folder.

share|improve this answer
    
Not gonna happen. My users can mount from their workstations or from servers. –  luckytaxi Apr 12 '10 at 14:31
3  
@luckytaxi: This is why planning network security is so important. I highly recommend conisdering retooling your network before the company grows more, and the problems become much worse. I do understand what this is asking; but it's pain now, or more later. –  Chris S Apr 12 '10 at 14:46
1  
For NFS to work well on a network, you need some form of centralised UID management (LDAP, NIS, rsyncd /etc/passwd), and ideally very controlled access to root accounts. –  xenny Apr 12 '10 at 17:09

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.