getlock 4.0

A lockfile utility that uses kernel locking, rather than just creating a lockfile, so that in the event of system shutdown, app being killed, or whatever, other apps are not blocked by the undeleted lockfile. Feature set includes: multiple lockfiles, wait-time to obtain lock, kill lockfile owner, run a script on lock failure, run app with specified user/group, 'nohup', fork into background and create lockfiles 'close on exec' so they are not inheritied by child processes.

Tags utility file-locking cli c
License GNU GPLv3
State stable

Recent Releases

4.028 Jan 2025 03:15 major feature: Add -nopriv/-nosu/-P flag to prevent priviledge elevation on linux. Better de/warning messages/logs. Added CHANGELOG. Added manpage.
1.014 Feb 2019 11:43 minor feature: This release adds the '-C' 'close on exec' flags, for those rare situations when you don't want all processes run under the lock to inherit the lockfile (like when launching something out of a cron job that will be long-running).