introduction
The Network File System (NFS) is a protocol that allows access to files on a server in a manner similar to accessing local files.
SUSE Linux Enterprise Server SP1 installs NFS v4.2, which introduces support for :
- sparse files,
- file pre-allocation,
- server-side clone and copy, application data block (ADB),
- and labeled NFS for mandatory access control (MAC) (requires MAC on both client and server).
The Network File System (NFS) is a standardized, well-proven and widely supported network protocol that allows files to be shared between separate hosts.
The Network Information Service (NIS) can be used to have a centralized user management in the network. Combining NFS and NIS allows using file and directory permissions for access control in the network. NFS with NIS makes a network transparent to the user.
In the default configuration, NFS completely trusts the network and thus any machine that is connected to a trusted network. Any user with administrator privileges on any computer with physical access to any network the NFS server trusts can access any files that the server makes available.
NFS network diagram
before moving to configure NFS
letus to have a look to above network diagram
we have user called ali@pioneers.lab from IT staff who is working on computer IT161 on subnet LAN
Ali would like to access folder called /resources on SLES124 on subnet [servers farm ]
OK, configuring NFS process involved with the following steps :
- on SLES server install package NFS
- configure NFS [select domain : pioneers.lab ] + [what to share : /resources ]
- start service nfs [please remember d stand for daemon which meaning service ]
- open NFS on SLES firewall
- on network Firewall PFsense : open port 2049 for NFS
- on client compute : install NFS client
- on client compute : mount NFS folder
- connect to NFS folder [ /resources ] from computer IT161
Step 01 : install package [NFS] on SLES
first of all we have to check if package nfs-kernel-server [which is responsible of running NFS ] is installed or NOT
use command :
zypper info nfs-kernel-server
if NFS is NOT installed > then simply install it using command
zypper install --no-confirm nfs-kernel-server
Step 02 configure NFS
step02 involved configuring NFS by
- open file /etc/idmapd.conf and set domain name
- and also open file /etc/exports and set permission >
please note : for file permission > we will have fully separated article about it
Step 06 : on client computer IT161 install NFS client
on client computer [IT161] which is windows 10 ] > install nfs client
- Open Start > Control Panel > Programs.
- Select Turn Windows features on or off.
- Select Services for NFS.
- Click OK.