PDA

View Full Version : [ubuntu] Easy Question! - Permissions Related



nuclearj
August 21st, 2012, 05:24 AM
Hello, I just installed 12.04 64bit Server and also installed NFSv4 and can mount the share/export. However, I cannot write anything to it.

The folder properties say that I am not the owner so I cannot change the permissions. Which I tried with one of those chmods... this just hit me, should I have started with a chown?

I'm a not a complete noob. More like a hack and slash, shotgun, spaghetti on the wall kinda linux user... I hope that communicates. Thanks!

LHammonds
August 21st, 2012, 07:51 AM
Anytime I create files/folders, I make sure the permissions are correct.

1st - I set ownership if necessary using chown
2nd - I set permissions using chmod
3rd - I make sure the stuff is in the correct logical locations

Also, when mounting file systems or sharing folders, make sure the mount point is mounted like you think it should. If you are expecting write/delete access, do not mount it as read-only because no matter what permissions/rights you have, you cannot modify a read-only access point unless you re-mount it as not read-only.

LHammonds

nuclearj
August 21st, 2012, 07:07 PM
Ok I will try that out tonight. Another question, Do I set the folder ownership permissions from within the server via ssh? Or do I set the permissions on the server from the client side?

sandyd
August 21st, 2012, 07:28 PM
Hello, I just installed 12.04 64bit Server and also installed NFSv4 and can mount the share/export. However, I cannot write anything to it.

The folder properties say that I am not the owner so I cannot change the permissions. Which I tried with one of those chmods... this just hit me, should I have started with a chown?

I'm a not a complete noob. More like a hack and slash, shotgun, spaghetti on the wall kinda linux user... I hope that communicates. Thanks!
What are you NFSing to?

If you are not using the same domain and/or synced uids/gids on NFS4 (this is only on NFS4!) for both the client and the server, it doesn't work.

NFS4 works on uids/gids, not names ;)

LHammonds
August 21st, 2012, 11:30 PM
Do I set the folder ownership permissions from within the server via ssh? Or do I set the permissions on the server from the client side?
I only manage my servers via SSH so I cannot give any advice beyond that.

LHammonds

nuclearj
August 22nd, 2012, 12:43 AM
What are you NFSing to?

If you are not using the same domain and/or synced uids/gids on NFS4 (this is only on NFS4!) for both the client and the server, it doesn't work.

NFS4 works on uids/gids, not names ;)

The client and server are both on the same network. That would mean they are on the same domain. Is that correct?

nuclearj
August 22nd, 2012, 12:44 AM
I only manage my servers via SSH so I cannot give any advice beyond that.

LHammonds

I see what you are saying. I will change the folders permissions on the server through ssh. I'll report back later!

sandyd
August 22nd, 2012, 06:02 AM
The client and server are both on the same network. That would mean they are on the same domain. Is that correct?
Did you configure both the client and the server with idmapd? (/etc/idmapd.conf)

Check that, then make sure the user's uid/gids match on each system.

For example, if you have a user that you are accessing NFS with, called

"a" with a gid of "2001", and a uid of "2001", you will also need a user named "a" with a gid of "2001", and a uid of "2001" on the server.
Then, chown the files on the server to the user and its group.

nuclearj
September 10th, 2012, 05:43 AM
Hey just wanted to say thanks for the help. I did get the folder to communicate.