What's the best way to mount an NFS share during boot?
Asked
Active
Viewed 503 times
1 Answers
3
What is "better" depends on your needs. If it is your home box, I'd go with autofs. If you add an entry in /etc/fstab
, which requires mount at boot time and there is anything wrong with the NFS server, then your boot will hang. Autofs based solution will let you boot every time, also if there's a problem with your NFS server.
If you decide to use fstab
anyhow, then add netdev
option. This prevents mount attempt until networking is up.

Paweł Brodacki
- 6,511
- 20
- 23
-
Great answer! This is on a server so I'll probably go with autofs. – Trent Scott Sep 18 '11 at 06:09
-
Look it up in your `man` page for `mount`. It's possible, that the option varies between versions/distributions. I took mine from RHEL 6 man page – Paweł Brodacki Sep 18 '11 at 06:20