From the source server:
· Edit /etc/exports and add the following line:
/directory_to_share HOSTNAME(rw,no_root_squash)
Note: HOSTNAME = IP or hostname of server mounting the share, replace rw with ro for read-only
· Start NFS daemon
# service nfs start
· Export the share
#exportfs -a
· Confirm if the share has been exported
#exportfs
From the destination(mounting) server:
· Start the NFS daemon
# service nfs start
· Create the mount point
# mkdir /mountdir
· Backup /etc/fstab file (mounting table)
# cp /etc/fstab /etc/fstab.old
· Edit /etc/fstab and add this line:
IP_OF_SOURCE:/shared_directory /mountpoint nfs defaults 0 0
· Mount the share by command line
# mount /mountpoint
· Confirm that it is mounted
# df -h /mountpoint
No comments:
Post a Comment