Setting NFS mount point directory permissions and owner
8,094
The permissions in this case come from the remote host, website.com
. The mount point permissions are superseded by the remote filesystem's permissions.
If you need to prevent others from accessing it, mount it one level deeper, ie /mnt/b/backup
, and chmod 700 /mnt/b
beforehand. (You could change perms on /mnt
but probably that's going to interfere with access to other mount points.)
Related videos on Youtube
Comments
-
Mech over 1 year
I currently have an NFS mounted
website.com:/var/sites/backups0 /mnt/backup nfs rsize=8192,wsize=8192,timeo=14,intr
The problem is, this mounts 777 permissions and I want it to be 700, the directory is set to 700.
dmask and dir_mode both are invalid options, the man page didnt say anything about mode permissions either. How do I lock this down to 700 root access only?
-
Mech about 14 yearsI already did that to some degree locking down mnt to 770 which works just fine since it's not often anything is mounted. I think I can also lock down the permissions on website.com so that should get me everything I need. Thanks a ton.
-
fission about 14 yearsGreat! No worries. :-)