cron problem
Natanael Copa
natanael.copa at gmail.com
Fri Aug 25 13:15:43 UTC 2006
Hi,
I have a problem that I need an advice to solve.
My alpinelinux project is run from RAM. The idea is, if you need
persisten /var, you need a disk. Only /etc is backed up since all system
configuration goes there.
Now, as a part of the system configuration, a user might want to add
custom cronjobs. In a debian system he can put stuff in /etc/cron.d
or /etc/crontab or /etc/cron.{daily,weekly,monthly}.
But with busybox crond its impossible to implement something like that,
without depending on /var/spool/cron/crontabs.
I can provide a default /var/spool/cron/crontab/root that will
run-parts /etc/cron.{daily,weekly,montly} at fixed times but then it
will not be possible for the user to control *when* the jobs will be
executed.
So, I'm practically asking for support of reading /etc/crontab. Even a
stripped down crond that only reads /etc/crontab would be a help.
So what do you suggest? A patch that adds /etc/crontab support to
current crontab? I don't rally knwo how to do that (without being ugly)
since it probably would need to uses stat to check when the file is
changed rather than creating a "cron.update" file.
Or should I create a new ucrond applet, that *only* reads /etc/crontab
and has no user crontabs support? It will check current time with
stat(2) and re-read if it has changed.
Other ideas?
--
Natanael Copa
More information about the busybox
mailing list