Wednesday 28 December 2011

NFS Network File Service

NFS
NETWORK FILE SERVICE
TO CHECK THE PACKAGE AS FOLLOWS
yum list nfs-utils
IF THE RPM IS NOT AVAILABLE INSTALL THROUGH YUM
yum install nfs-utils
Before configuring the NFS server, observe the RPC services you are now running
rpcinfo -p
MAIN CONFIGURATION SHOULD BE WRITTEN IN /etc/exports
vi /etc/exports
Now we are going to share the '/var/ftp/pub' directory to the redhat.com network, enter the following:
/var/ftp/pub
or
/var/ftp/pub
*.redhat.com(rw,sync,no_root_squash)
192.168.0.0/255.255.255.0(rw,sync,no_root_squash)
START THE DAEMON SERVICES
service portmap start/restart/stop/reload
service nfs start/restart/stop/reload
chkconfig portmap on
chkconfig nfs on
TO VERIFY THE FILES ARE EXPORTED USING THE FOLLOWING
showmount -e localhost
or
/var/ftp/pub *.example.com
/var/ftp/pub 192.168.0.0/255.255.255.0
exportfs -v
/var/ftp/pub
/var/ftp/pub
192.168.0.0/255.255.255.0(rw,wdelay,no_root_squash)
*.example.com(rw,wdelay,no_root_squash)
CLIENT SIDE CONFIGURATION:
To check which directory is exported
showmount -e
mount the shared directory to your local file system
mount 192.168.0.x:/var/ftp/pub /mnt

No comments:

Post a Comment