-
Notifications
You must be signed in to change notification settings - Fork 4
Network File System (NFS)
- Before You Start
- Enable NFS on your Synology NAS
- Assign NFS permission to shared folders
- Mount shared folders via NFS
- Configure Automount
Login to the Synology DiskStation Manager (DSM) from your web browser (you can find the IP address) from your router home page, most routers, depending on brand, use either 192.168.1.1 or 192.168.0.1
http://<IP-ADDRESS>:5000/
- Open your Synology Control Panel from the Desktop.
- Click the
File Services
option in theFile Sharing
tab. - Next, check the
Enable NFS
box under theNFS Service
tab. - Confirm your choice by clicking the Apply button.
After you’ve enabled NFS on your Synology NAS, you will also need assign NFS Permissions to Shared Folders. To do that, follow these steps:
- Open your Synology Control Panel from the Desktop.
- Select the
Shared Folder
tab from the menu on the left. - Select the folder you want to share, for examples:
video
. - Then, click the
Edit
button. - Click the
Permissions
tab. - Check the
Read/Write
box foradmin
. - Next, go to
NFS Permissions
tab- Click
Create
orEdit
- Set
Hostname or IP*
to yourPC IP Address
- Set
Privilege
toRead/Write
- Set
Squash
toMap all users to admin
- Set
Security
tosys
- Check
Enable asynchronous
box - Check
Allow connections from non-privileged ports
box - Check
Allow users to access mounted subfolders
box
- Click
- Click OK
- Click OK once more to confirm the rule creation.
Once you have completed the steps above, you can mount the shared folder with your NFS client. To do that, follow these steps:
$ pacman -S nfs-utils
Start server
$ sudo systemctl enable rpcbind.service
$ sudo systemctl start rpcbind.service
$ sudo systemctl enable nfs-client.target
$ sudo systemctl start nfs-client.target
$ sudo systemctl start remote-fs.target
Manual mounting Show the server's exported file systems:
$ showmount -e DiskStation
Create a directory where you want to mount DiskStation
:
$ mkdir /home/sayem/DiskStation
Then mount omitting the server's NFS export root:
# sudo mount -t nfs DiskStation:/volume1/video /home/sayem/DiskStation
Make sure DiskStation folder exist in
/sayem/home/DiskStation
Install the autofs
packages
You can install the autofs
with this command:
sudo pacman -Syu autofs
You can verify that the autofs
files have been placed in the etc directory:
cd /etc; ll auto*
total 40K
-rw-r--r-- 1 root root 15K Aug 2 2018 autofs.conf
-rw------- 1 root root 232 Aug 2 2018 autofs_ldap_auth.conf
-rw-r--r-- 1 root root 816 Aug 2 2018 auto.master
drwxr-xr-x 2 root root 4.0K Aug 2 2018 auto.master.d
-rw-r--r-- 1 root root 524 Aug 2 2018 auto.misc
-rwxr-xr-x 1 root root 902 Aug 2 2018 auto.net
-rwxr-xr-x 1 root root 2.2K Aug 2 2018 auto.smb
Edit the /etc/autofs/auto.master
file and append the following:
/home/sayem/DiskStation /etc/autofs/auto.home --time-out=5 --ghost
Next, create the auto.home
file in /etc/autofs
directory:
sudo /etc/autofs/auto.home
Add the following to the /etc/autofs/auto.home
configuration file:
video -fstype=nfs,rw,soft,retry=0 DiskStation:/volume1/video/
Start the autofs
service:
sudo systemctl enable autofs.service
And then enable so that it will run at boot:
sudo systemctl start autofs.service
Done. Now you should be able to access your Synology file at ~/DiskStation
directory.
- Home
- Bootable USB Installer
- BIOS
- Pre-installation
- Installation
- Configure System
- Post Installation
- Extra
- Troubleshooting
- Development
- DevOps