|Link to this page: http://wiki.scn.sap.com/wiki/x/PARnFQ|
To explain the importance of correct mount point setup in an SAP environment.
What type of mounts are available? What to consider? What are the recommendations?
What mount options are available?
Hard and soft. It determines the recovery behavior of the NFS client after an NFS request times out. If neither option is specified (or if the hard option is specified), NFS requests are retried indefinitely. If the soft option is specified, then the NFS client fails an NFS request after retrans retransmissions have been sent, causing the NFS client to return an error to the calling application.
What to consider?
soft timeout can cause silent data corruption in certain cases. As such, use the soft option only when client responsiveness is more important than data integrity. Using NFS over TCP or increasing the value of the retrans option may mitigate some of the risks of using the soft option.
An NFS file system that is mounted with the soft option returns an error if the server does not respond. The hard option causes the mount to continue to retry until the server responds. If a file system is mounted by using the hard option and becomes unavailable, an application that uses this file system hangs until the file system becomes available.
To improve performance, NFS clients cache file attributes. Every few seconds, an NFS client checks the server's version of each file's attributes for updates. Changes that occur on the server in those small intervals remain undetected until the client checks the server again. The noac option prevents clients from caching file attributes so that applications can more quickly detect file changes on the server. In addition to preventing the client from caching file attributes, the noac option forces application writes to become synchronous so that local changes to a file become visible on the server immediately. That way, other clients can quickly detect recent writes when they check the file's attributes. Using the noac option provides greater cache coherence among NFS clients accessing the same files, but it extracts a significant performance penalty.
Selects whether to allow signals to interrupt file operations on this mount point. If neither option is specified (or if nointr is specified), signals do not interrupt NFS file operations. If intr is specified, system calls return EINTR if an in-progress NFS operation is interrupted by a signal. Using the intr option is preferred to using the soft option because it is significantly less likely to result in data corruption.
What are the recommendations?
Although soft-mounting the directories causes the error to be detected sooner, it runs a serious risk of data corruption. This is what we need to avoid in an SAP environment.
- Always use noac option for soft-mounted directories (if you do prefer soft-mounts - not recommended).
- In general, read/write directories should be hard-mounted. Use the intr option to mount the hard-mounted directories, which allows the user to interrupt from the keyboard a process that is in a retry loop.
Important note for Linux The intr / nointr mount option is deprecated after kernel 2.6.25. Only SIGKILL can interrupt a pending NFS operation on these kernels, and if specified, this mount option is ignored to provide backwards compatibility with older kernels. In this case use option 1 (soft mount with noac)
Troubles with noac? Refer to Performance impact of disabling NFS attribute caching
What SAP directories is it about?
- /sapmnt/SID/global (joblog, TemSe)