Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

What is the difference between using auto.master and having autofs automount your NFS mountpoints versus just putting the info in fstab? Linux Red-Hat 5/6

share|improve this question

1 Answer 1

up vote 2 down vote accepted

With fstab, the advantage is the remote filesystem will be mounted on system (when the noauto mount option is not used).

Additionally, it depends how the mount point is defined. There are two options which determines the recovery behaviour when the NFS client can't reach the server. With the hard option (default one), the boot process will pause if there is a problem mounting the nfs share and repeated tries are made to mount the share indefinitely. If the soft option is used, then the mount fails after retrans retransmissions have been sent.

On the other hand, autofs only mounts nfs shares when they are needed and accessed.

share|improve this answer
That was my understanding of autofs as well; so autofs will react to a stat, or other filesystem request which references that mountpoint by first mounting the NFS volume and then completing the request? Does it immediately unmount the NFS after the operation completes? –  Gregg Leventhal Dec 21 '13 at 18:12
@GreggLeventhal autofs can be configured to unmount after a period of inactivity. Setting the timeout to 0 would not be a good idea since it would lead to very frequent unmount-mount cycles when you access two files in succession. –  Gilles Dec 21 '13 at 23:51
What is the benefit to that versus leaving it mounted via fstab? –  Gregg Leventhal Dec 22 '13 at 15:06

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.