NFS hard and soft mounts
When the backup-archive client connects to an NFS file system, you can use either a hard mount or a soft mount.
The client uses the nfstimeout option value to determine how long to wait for an NFS system call to respond before timing out; this setting applies to hard and soft mounts. The default is 0 seconds. This means that the client uses the default behavior of NFS system calls.
Be aware of the consequences of hard and soft mounts if the mount becomes stale (for example, if the server for the file system is not available).
- Hard mount
- If the NFS file system is hard mounted, the NFS daemons try repeatedly to contact the server. The NFS daemon retries will not time out, they affect system performance, and you cannot interrupt them, but control returns to the client when the nfstimeout value is reached.
- Soft mount
- If the NFS file system is soft mounted, NFS tries repeatedly to
contact the server until either:
- A connection is established
- The NFS retry threshold is met
- The nfstimeout value is reached
When one of these events occurs, control returns to the calling program.Note: On UNIX and Linux systems, the nfstimeout option can fail if the NFS mount is hard. If a hang occurs, deactivate the nfstimeout option and mount the NFS file system soft mounted, as follows:
The parameters are defined as follows:
mount -o soft,timeo=5,retry=5 machine:/filesystem /mountpoint
- Generates a soft mount of the NFS file system. If an error occurs, the stat() function returns with an error. If the option hard is used, stat() does not return until the file system is available.
- Sets the timeout period for a soft mount error to n tenths of a second.
- Sets the number of times to try the mount, where n is an integer; the default is 10000.