File locking


Gennaro Cuofano
by Gennaro Cuofano
Loading Comments
Affiliate Disclosure

File locking is a mechanism that restricts access to a computer file by allowing only one user or process access at any specific time. Systems implement locking to prevent the classic interceding update scenario. It may also refer to additional security applied by the user of computer either by using Windows security, NTFS permissions or by installing a third party file locking software. Most operating systems support the concept of record locking, which means that individual records within any given file may be locked, thereby increasing the number of concurrent update processes. Database maintenance uses file locking, whereby it can serialize access to the entire physical file underlying a database. Although this does prevent any other process from accessing the file, it can be more efficient than individually locking a large number of regions in the file by removing the overhead of acquiring and releasing each lock.