[linux-elitists] A better cron: large production environments

Karsten M. Self karsten at linuxmafia.com
Fri May 7 19:57:22 PDT 2010


on Fri, May 07, 2010 at 06:20:10PM -0700, George Georgalis (george at galis.org) wrote:
> On Fri 07 May 2010 at 05:09:22 PM -0700, Karsten M. Self wrote:
> >I'm kicking ideas around for a better cron system (or framework for the
> >existing system) which might help address some of the shortcomings of
> >cron as are being experienced now, particularly in notification and
> >messaging.
> 
> mon will cover most if not all of your goals. 
> https://mon.wiki.kernel.org/index.php/Main_Page
> 
> using it as a cron replacement has come up before,
> that application is not supported, it's optimized
> as a service monitor, but as long as you write your
> jobs as tests, you should be good to go.

Clarifying:  a cron enhancement rather than replacement would be
preferable (institutional inertia and all that jazz), though if
something compelling enough shows up it might be worth a shot.

I'm thinking of a shell script or functional wrapper (hrm... the
sysvinit start/stop scripts as implemented by Debian are kinda close).
Basically:

  - specify the runtime parameters (as discussed previously)
  - note the start time (log?), prolly using launcher's PID for tracking.
  - submit the job (background), redirecting stdout and stderr (and also
    logging it?) and wait for its completion.
  - check exit status.
  - note the complete time (log?).
  - run any additional sanity/correctness checks on output(s), set
    message flags accordingly.
  - send appropriate notifications.


That wrapper itself would be what cron would invoke, the wrapper would
run the actual job (and handle the notifications/logging) independently
of cron.

This makes migrating numerous legacy scripts fairly transperant -- we're
adding one layer of infrastructure, but it's pretty light.


Peace.

-- 
Karsten M. Self <karsten at linuxmafia.com>        http://linuxmafia.com/~karsten
 What part of "gestalt" don't you understand?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://zgp.org/pipermail/linux-elitists/attachments/20100507/e7a97cc3/attachment.pgp>


More information about the linux-elitists mailing list