Re: [PROPOSAL] Cron jobs
On Thu, 11 Mar 1999, Daniel Quinlan wrote:
> ------- start of proposal --------------
> Cron jobs
> Packages may not touch the configuration file /etc/crontab, nor may
> they modify the files in /var/spool/cron/crontabs.
> If a package wants to install a job that has to be executed via cron,
> it should place a file with the name if the package in one of the
> following directories:
> As these directory names say, the files within them are executed on a
> daily, weekly, or monthly basis, respectively.
> If a certain job has to be executed more frequently than `daily,' the
> package should install a file /etc/cron.d/<package-name> tagged as
> configuration file. This file uses the same syntax as /etc/crontab and
> is processed by cron automatically. (Note, that scripts in the
> /etc/cron.d directory are not handled by anacron. Thus, you should
> only use this directory for jobs which may be skipped if the system is
> not running.)
> All files installed in any of these directories have to be scripts
does "these" include /etc/cron.d ? I think, this is wrong.
> (shell scripts, Perl scripts, etc.) so that they can easily be
> modified by the local system administrator. In addition, they have to
> be registered as configuration file.
> The scripts in these directories have to check, if all necessary
> programs are installed before they try to execute them. Otherwise,
> problems will arise when a package was removed (but not purged), since
> the configuration files are kept on the system in this situation.
> ------- end ----------------------------
> Suggested modifications:
> - replace should with shall (makes sense for all cases)
> - all scripts must be XPG3 Shell compliant scripts, using a
> standard location for XPG3 Shell to be determined
why? imho /etc/cron.daily/* simply has to be an executable. But it's not
so important for me.
> Open questions:
> - do we require anacron in the standard base system?
I think not. We (SuSE) have a script for /etc/cron.*, that works with
lastrun files. That means, it is not neccessary, to run the machine 24x7.
Together with an crontab entry like
0 0 * * * root rm -f /var/cron/lastrun/cron.daily
there will be no time shifting problem...
> - if anacron, should there be a configuration option (for any package
> cron job to disable/enable anacron operation)?
> - if anacron, should scripts in /etc/cron.d be handled by anacron?
> - do we use the above system or an "install-cron" program wrapper?
I like the above system very much more than an install-cron wrapper.
Burchard Steinbild <email@example.com>
Tel: +49-911-74053-0 Schanzaeckerstr. 10
Fax: +49-911-7417755 90443 Nuernberg, Germany