Re: Cron daemon with better precision?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Fri, 2009-01-16 at 13:46 -0600, Tim Nelson wrote:
> Greetings list-
> 
> I'm on the hunt for a cron scheduler that supports definitions to the second. Obviously, every cron daemon supports minute/hour/etc but I have a special application that requires finer granularity.
> 
> I know I know... someone will say "The load will be horrendous on your system" or "Why don't you simply schedule your cron every minute and make up the higher precision in your application?". Unfortunately, this will not work. I really need a cron daemon that can schedule to the second.
> 
> All ideas/thoughts/suggestions/etc welcome. Thank you!

If the other suggestion doesn't meet your needs, consider the following.

Even a cron scheduler with 1 second resolution _may_ not give you what
you need. This is because initializations may cause the application to
start running too late. This possibility seems probable based on the
need for 1 second resolution.

Of course, you could set the cron to kick off some average number of
seconds earlier, but variability of system load, cache contents, disk
I/O status, etc. could cause it to start sooner or later on any given
invocation.

IMO, any application designed to need 1 second resolution (if that is
the case here) should run as a daemon and handle the timing needs itself
or accept signals (such as SIGUSR1 or whatever) from an external
"supervisor" that tells the daemon "do it now". That way everything is
already in memory (presuming swap is disallowed) and only system
controlled resources, such as cache, buffers and disk I/O status could
cause high variability. Those issues can be handled by ensuring load
versus capacity is adequate during critical times. Of course, that might
also then allow a cron-like dispatching process to be adequate for the
task. It just depends on the host configuration for resources and load.

> 
> Tim Nelson
> <snip sig stuff>

If this is for a process control application with tight timing
constraints, I suggest a system dedicated to the task. Long ago and far
away, I designed and implemented a custom hardware and software system
to capture many items of data from a large number of textile looms. This
was before such was available "off the shelf". It ran on a true UNIX
system on 486DX/2 and 586 hardware. From that background I can strongly
suggest dedicated hardware if your application is similar.

-- 
Bill

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux