HomeFreeBSD

MFC r334817, r334910

Description

MFC r334817, r334910

r334817:
Add new functionality and syntax to cron(1) to allow to run jobs at a
given interval, which is counted in seconds since exit of the previous
invocation of the job. Example user crontab entry:

@25 sleep 10

The example will launch 'sleep 10' every 35 seconds. This is a rather
useless example above, but clearly explains the functionality.

The practical goal here is to avoid overlap of previous job invocation
to a new one, or to avoid too short interval(s) for jobs that last long
and doesn't have any point of immediate launch soon after previous run.

Another useful effect of interval jobs can be noticed when a cluster of
machines periodically communicates with a single node. Running the task
time based creates too much load on the node. Running interval based
spreads invocations across machines in cluster. Note that -j/-J won't
help in this case.

r334910:
Remove old, dead compat code.

We no longer need to od these things conditionally, and the fallbacks
are to 4.2BSD era defaults, which nobody uses anymore. Vixie cron has
diverged from upstream anyway in our tree, and it's not clear there's
actually a viable upstream anymore. Plus, we don't follow the
vendor-supplied code pattern here.

I'm doing this to reduce false positives from grep.

Details

Provenance
kevansAuthored on
Parents
rS346512: MFC r330358, r330360
Branches
Unknown
Tags
Unknown