http://www.perlmonks.org?node_id=11125419


in reply to Preventing multiple instances

Another solution is to run your script as a daemon so there is alway just a single process running, and it can manage not running over itself internally. It really just comes down to a sleep 120;. Just don't start more than once daemon at a time :)