You are on page 1of 1

6/10/2016

Installingandconfigringnfsserverstepbysteppart4

Installingandconfigringnfsserverstepbysteppart4
ConnectingClientsViaNFS
SettingupaclienttouseNFSisrelativelysimplewhenyouhavetheNFSserverinplace.Letssetupthe
Client01systemtouseashareontheRHEL01NFSserver.
Step1.Tostart,youneedtoinstalltherequiredpackages:
#yuminstallynfsutilsnfs4acltools
ThesetwopackagesincludethenecessaryfilesforyoutoconnecttotheNFSserverandusetheexported
resources.Ontheclientside,youneedonlytherpcbindservicerunningtomountNFSresourcesontheserver.
Step2.Ensurethattherequiredserviceissettostartonboot:
#chkconfigrpcbindon
YoucannowcreatesomedirectoriestoholdtheNFSsharesonthelocalsystem.
Step3.Createtwolocaldirectories:
#mkdir/mnt/{company_data,temp}
Step4.Mountthecompany_dataNFSshare:
#mounttnfs172.168.1.1:/opt/company_data/mnt/company_data
Assumingyourpermissionsandsecurityrestrictionsarecorrectlyinplace,youshouldnowbeabletomoveinto
the/mnt/company_datadirectoryandactuallyaccesstheNFSshareontheserver.Ifyoudontwanttoalways
mountNFSsharesafteryoursystemhasbooted,youcan,ofcourse,addanentrytothe/etc/fstabfiletohave
themmountedautomaticallyatsystemboot.
Step1.Inthe/etc/fstab,addthefollowingline:
#nano/etc/fstab
rhel01:/opt/company_data/opt/company_datanfs
rw,sync00
Itmountstheremote/opt/company_datatothelocal/mnt/company_datadirectory.
Step2.Saveyourfileandexit.
Step3.Usingthemountcommand,youcanverifythattheresourcewas
mountedproperly:
#mount|grepnfs
sunrpcon/var/lib/nfs/rpc_pipefstyperpc_pipefs(rw)
nfsdon/proc/fs/nfsdtypenfsd(rw)
172.168.1.1:/homeon/mnt/temptypenfs
(rw,vers=4,addr=172.168.1.1,clientaddr=172.168.1.10)
172.168.1.1:/opt/company_dataon/mnt/company_datatypenfs
(rw,vers=4,addr=172.168.1.1,clientaddr=172.168.1.10)
Theremoteresourceshouldnowbeavailablejustasifitwerealocalresource.
PostedbyAbdulRaziqat2:27PM
Labels:NFS

http://redhatenterpriselinux.blogspot.com/2012/07/installingandconfigringnfsserver_3269.html#.V1uHgfkrKUk

1/1

You might also like