Support #645
NFS Sharing on Arch
Status:
Closed
Priority:
Normal
Assignee:
Category:
Network Attached Storage
Target version:
Description
- Table of contents
- Prepare the environment
- Setup NFS Server
- Mount the NFS Share
- Resources
This is a guide on mounting a remote NFS share on Arch linux.
Prepare the environment¶
- Make sure the system is up to date:
sudo pacman -Syu
Setup NFS Server¶
- Install nfs-utils package:
pacman -S nfs-utils
- Edit the
exports
file:vi /etc/exports
- Setup a read-only public share to the 192.168.1.0 network:
/srv/nfs/public 192.168.1.0/24(ro,all_squash,insecure,no_subtree_check)
- Setup a read-only public share to the 192.168.1.0 network:
- Start and enable the nfs-server at boot:
systemctl enable nfs-server systemctl start nfs-server
Mount the NFS Share¶
- Install nfs-utils package:
pacman -S nfs-utils
- Start and enable rpcbind.service,nfs-client.target and remote-fs.target services at boot:
systemctl enable rpcbind.service systemctl enable nfs-client.target systemctl enable remote-fs.target systemctl start rpcbind.service systemctl start nfs-client.target systemctl start remote-fs.target
Manual Mounting¶
- Mount NFS share:
mount -t nfs nas.example.com:/srv/nfs/public /media/public
/etc/fstab¶
- Using fstab is useful for a server which is always on, and the NFS shares are available whenever the client boots up. Edit /etc/fstab file:
vi /etc/fstab
- And add an appropriate line reflecting the setup. Again, the server's NFS export root is omitted.
nas.example.com:/srv/nfs/public /media/public nfs rsize=32768,wsize=32768,timeo=900,retrans=5,_netdev 0 0
- And add an appropriate line reflecting the setup. Again, the server's NFS export root is omitted.
Resources¶
Updated by Daniel Curtis over 9 years ago
- Status changed from New to In Progress
- % Done changed from 0 to 50
Updated by Daniel Curtis over 9 years ago
- Status changed from Resolved to Closed
- % Done changed from 50 to 100
Updated by Daniel Curtis almost 7 years ago
- Subject changed from Mount An NFS Share on Arch to NFS Sharing on Arch
- Description updated (diff)