NFS on Fedora · uwot.eu
another meaningless subtitle

NFS on Fedora

· by fabio · Read in about 1 min · (164 Words)
fedora Fedora 26 NFS

NFS allow to share files and folders over network and is much much faster than samba while using way less resources.
To setup a NFS server on Fedora 26 install:

$ dnf install nfs-utils

Shared directories are listed in the following configuration file:

# Syntax
#<path> <ipaddr>(<option>)
/home/user/Public 192.168.0.0/255.255.255.0(ro,sync)

More information can be found here: https://fedoraproject.org/wiki/Administration_Guide_Draft/NFS
In the above example the the directory “/home/user/Public” is can be accessed by every client in the same LAN with read-only permissions.
In case SELinux is active and enforcing some further configuration might be required:

### Allow nfs to share every file directory with read-only attribute
$ setsebool -P nfs_export_all_ro 1
### More NFS related SELinux flags can be found using the following command
$ semanage boolean -l | grep nfs

Enable NFS daemon service and start it

$ systemctl enable nfs
$ systemctl start nfs

To mount a NFS share on a client type:

### mount -t nfs <server_IP>:/<path_to_dir> <mountpoint>
$ sudo mount -t nfs media:/home/user/Public /mnt/nfsshare/