Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1253
  • Last Modified:

Bad NFS Permissions on a Share - CentOS 6.2

I created an NFS share on CentOS 6.2 and for the most part it works great. I share a file out from ServerA to ServerB and I can view them on both. The only problem is that on ServerB, the permissions are screwed up and the file is read-only, even if I create the file on ServerB. Here is what I see when I run ls -al on the share:

-rw-r--r--.  1 4294967294 4294967294    7 Sep 11 07:41 test2.txt
-rw-r--r--.  1 4294967294 4294967294    7 Sep 11 07:56 test3.txt
-rw-r--r--.  1 4294967294 4294967294    7 Sep 11 07:49 test.html

-rw-r--r--.  1 nfsnobody nfsnobody    7 Sep 11 07:41 test2.txt
-rw-r--r--.  1 nfsnobody nfsnobody    7 Sep 11 07:56 test3.txt
-rw-r--r--.  1 nfsnobody nfsnobody    7 Sep 11 07:49 test.html

Any help is greatly appreciated!

Also - my etc/exports file shows "/var/share *(rw,sync,all_squash)" and I restarted NFS service afterwards.
  • 3
  • 2
1 Solution
If you're mounting out of /etc/fstab, do they differ between servers? Are they both 32-bit, 64-bit, or mixed? It looks like nfsnobody is UID 2^32-2 on server A, but not on server B. So, you have some options:

Use a mount option to translate UID 2^32-2 to your user
Synchronize the UID/GIDs between the two systems
Set a umask such that created files get less restrictive permissions than 644
brendan-amexAuthor Commented:
Thank you for your post. So I got the permissions to look correct with changing the Domain in the config file /etc/idmapd.conf, but I still get permission denied when trying to edit a file on ServerA that was created on ServerB. Am I not supossed to be able to edit any files inside the share on a different server?
It really does depend on the settings. What does


Open in new window

show on each server?
brendan-amexAuthor Commented:
Mount on Server that's shared out:
(nothing regarding the share)

Mount on client server:
server.domain:/var/shared on /var/shared type nfs (rw,hard,vers=4,addr=,clientaddr=
brendan-amexAuthor Commented:
Nothing needs to be mounted from the server to the client, right? Only the client to the server?

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now