actimeo is a common NFS mount option in Linux. actimeo=0 can make a big performance difference in the production environment.
What does actimeo mean in nfs mount?
The “actimeo=0” option means turn attribute caching off. The actimeo option actually makes the time duration the nfs client holds the various cache attributes like “acregmin”,”acregmax”,”acdirmin” and “acdirmax” to zero seconds, which means that the nfs client will need to look for the attributes everytime from the server.
This means that default mounts will be created with the option “actimeo=0” which sets the following options all to 0 also, to disable caching: acregmin, acregmax, acdirmin,acdirmax.
How to check if actimeo is enabled in Linux?
We can use /proc/mounts to check which mount options are used. The following output means that actimeo=0 is enabled.
10.124.202.133:/vol/testnfs /testnfs nfs rw,relatime,vers=3,rsize=32768,
ocal_lock=all,addr=10.124.202.133 0 0
Add or remove actimeo in production
In our env, shareplex runs on NFS storage. After we remove this mount option, shareplex performance improves a lot.
We suggest removing this mount option. When it is removed, the application can get the attributes from local memory, not remote storage. Local memory is much faster than NFS storage from the application perspective.
From our storage monitoring tool, we can see that the IOPS which are used for attributes drops a lot because these IOPS are not hitting storage anymore. Sometimes the application might get hang if we add this option. We need test this before we roll out to production.