NFS Mount - CentOS w/ multiple users

nitrobass24

[H]ard|DCer of the Month - December 2009
Joined
Apr 7, 2006
Messages
10,465
Background - Moving NZBGet and Sonarr to CentOS from Windows. Have multiple accounts: root, stephen(me), NZBGet, and Sonarr. Want all of the accounts to have access to the NFS mount on system startup.

As root I have mounted my Synology NFS share
Code:
[root@PVR stephen]# cat /etc/fstab

#
# /etc/fstab
# Created by anaconda on Thu Nov 24 13:21:52 2016
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/centos00-root /                       xfs     defaults        0 0
UUID=39652a6f-9beb-4497-879a-ca0acbf768f7 /boot                   xfs     defaults        0 0
/dev/mapper/centos00-home /home                   xfs     defaults        0 0
/dev/mapper/centos00-tmp /tmp                    xfs     defaults        0 0
/dev/mapper/centos00-var /var                    xfs     defaults        0 0
/dev/mapper/centos00-var_log /var/log                xfs     defaults        0 0
/dev/mapper/centos00-var_log_audit /var/log/audit          xfs     defaults        0 0
/dev/mapper/centos00-var_tmp /var/tmp                xfs     defaults        0 0
/dev/mapper/centos00-swap swap                    swap    defaults        0 0
diskstation.davis.local:/volume2/Home_Data/Downloads /mnt/nfs/Downloads         nfs     defaults,nosuid,noexec,nodev    0 0
diskstation.davis.local:/volume2/Home_Data/Movies /mnt/nfs/Movies         nfs     defaults,nosuid,noexec,nodev    0 0
diskstation.davis.local:/volume2/Home_Data/TV /mnt/nfs/TV         nfs     defaults,nosuid,noexec,nodev    0 0
This works great....as long as I am root.

How do I modify my fstab to make this available to all users on the system?
 
Are they not showing up as mounted when you run something like "df -h" as one of the other users?

It is late but nothing is jumping out at me at the moment why the other users would not see the 3 shares as mounted.
 
Last edited:
Background - Moving NZBGet and Sonarr to CentOS from Windows. Have multiple accounts: root, stephen(me), NZBGet, and Sonarr. Want all of the accounts to have access to the NFS mount on system startup.

As root I have mounted my Synology NFS share
Code:
[root@PVR stephen]# cat /etc/fstab

#
# /etc/fstab
# Created by anaconda on Thu Nov 24 13:21:52 2016
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/centos00-root /                       xfs     defaults        0 0
UUID=39652a6f-9beb-4497-879a-ca0acbf768f7 /boot                   xfs     defaults        0 0
/dev/mapper/centos00-home /home                   xfs     defaults        0 0
/dev/mapper/centos00-tmp /tmp                    xfs     defaults        0 0
/dev/mapper/centos00-var /var                    xfs     defaults        0 0
/dev/mapper/centos00-var_log /var/log                xfs     defaults        0 0
/dev/mapper/centos00-var_log_audit /var/log/audit          xfs     defaults        0 0
/dev/mapper/centos00-var_tmp /var/tmp                xfs     defaults        0 0
/dev/mapper/centos00-swap swap                    swap    defaults        0 0
diskstation.davis.local:/volume2/Home_Data/Downloads /mnt/nfs/Downloads         nfs     defaults,nosuid,noexec,nodev    0 0
diskstation.davis.local:/volume2/Home_Data/Movies /mnt/nfs/Movies         nfs     defaults,nosuid,noexec,nodev    0 0
diskstation.davis.local:/volume2/Home_Data/TV /mnt/nfs/TV         nfs     defaults,nosuid,noexec,nodev    0 0
This works great....as long as I am root.

How do I modify my fstab to make this available to all users on the system?

Most likely you just need to set rights to the mount point if it's owned by root at the moment. Fstab is ok, mount point rights are most likely the problem. Set # chmod -R 755 /mnt/nfs/TV and see if you can access it after that.
 
Most likely you just need to set rights to the mount point if it's owned by root at the moment. Fstab is ok, mount point rights are most likely the problem. Set # chmod -R 755 /mnt/nfs/TV and see if you can access it after that.

I'd go with this as well.

There's nothing in your fstab file which indicates that there's anything wrong. To modify what Boonie said a bit, I'd go with:

chmod -R 755 /mnt/nfs

This should allow all of the users to view any of the nfs directories.
 
Back
Top