Re: Ensure only single application instance.
- From: Frank Millman <frank@xxxxxxxxxxxx>
- Date: Fri, 29 Aug 2008 22:25:28 -0700 (PDT)
On Aug 29, 11:25 pm, Uberman <bhoo...@xxxxxxxxxxx> wrote:
On Fri, Aug 29, 2008 at 6:51 AM, Heston James <heston_ja...@xxxxxxxxxx> wrote:
Good afternoon all.
I have an application/script which is launched by crontab on a regular
basis. I need an effective and accurate way to ensure that only one instance
of the script is running at any one time.
The following is taken from the getmail FAQ -
------------------------------------------
If you need to prevent two instances of getmail from running
simultaneously, use any standard Unix method of providing a mutex for
this purpose. One example would be to run getmail under a program like
setlock (part of the daemontools package). Change your script or
crontab file to invoke getmail like this:
/path/to/setlock -n /path/to/lockfile /path/to/getmail [getmail
options]
There are other programs that provide functionality similar to
setlock.
------------------------------------------
HTH
Frank Millman
.
- References:
- Re: Ensure only single application instance.
- From: Timothy Grant
- Re: Ensure only single application instance.
- From: Uberman
- Re: Ensure only single application instance.
- Prev by Date: Re: Date Comparison and Manipulation Functions?
- Next by Date: Re: Which is faster?
- Previous by thread: Re: Ensure only single application instance.
- Next by thread: Re: Ensure only single application instance.
- Index(es):