Suggested Answer:See explanation below.
1. vi /etc/auto.master /mnt /etc /auto.misc --timeout=50 vi /etc/auto.misc data -rw,soft,intr server1.example.com:/data service autofs restart chkconfig autofs on When you mount the other filesystem, you should unmount the mounted filesystem, Automount feature of linux helps to mount at access time and after certain seconds, when user unaccess the mounted directory, automatically unmount the filesystem. /etc/auto.master is the master configuration file for autofs service. When you start the service, it reads the mount point as defined in /etc/auto.master.
Regarding the comments made in some posts=> which one to use static NFS mount (edit fstab) or autofs, well it is matter of preference but here points to keep in mind
• It is RHCSA exam and it clearly emphasizes on autofs
• Static NFS mount are manual and editing the fstab means prone to errors and hence there is good chance the system will NOT boot and also server1 where the share is hosted may be offline or network issue then you will need to go into emergency mode to repair that [reedit the fstab], even if boots will take long time to do so
• You don’t need to create any directory on server2 using autofs, where as with static NFS mount you will need to create one like /mnt/Data etc in advance hence more effort involved, plus you need to set the correct permissions
• Autofs onces configured correctly it works like Gem and hence Redhat emphasizing on it
follow below
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
adolfoale
Highly Voted 3 years, 10 months agokitkat
2 years, 5 months agokitkat
Highly Voted 2 years, 5 months agoLazylinux
Most Recent 3 months, 2 weeks agokenkct
2 years, 9 months agokysj
2 years, 9 months agosugisho
3 years, 4 months agosugisho
3 years, 4 months ago