File locking is a mechanism to restrict access to a file among multiple processes. It allows only one process to access the file in a specific time, thus avoiding the interceding update problem.
What does it mean to lock a file?
Locking/Unlocking Files. … Note: When you lock a file, it will show a lock icon, but you will still be able to edit it. When someone else locks a file, you will see a different lock icon, and you will not be able to modify the file unless you unlock it.
What is NFS file locking?
File locking allows one process to gain exclusive access to a file or part of a file, and forces other processes requiring access to the file to wait for the lock to be released. Locking is a stateful operation and does not mesh well with the stateless design of NFS.