Wednesday, May 24, 2023

Oracle Linux 7 -- How to Implement Singleton Scripts in Bash


You need to implement a singleton script in Bash, that is, a script that may have only single running instance


Use the utility script from

The script is aimed to help in implementation of singleton scripts, featured with automatic lock files clean up after abnormal script interruption, and also input parameters aware, different input parameters make different running instances of a script 


Copy paste the content of into your script, or


inside your script.

No comments: