Re: questions about cron.daily
Hi,
Greg Wooledge wrote:
> > > unicorn:~$ grep daily /etc/crontab
> > > 25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
Fred wrote:
> > I also would like to know when cron.daily scripts run. Greg's command does
> > not appear to reveal the time for that script. I ran Greg's command and got
> > the same result.
Pierre Frenkiel wrote:
> crontab -l
Plus:
man 5 crontab
which has in its section "EXAMPLE CRON FILE"
# run five minutes after midnight, every day
5 0 * * * $HOME/bin/daily.job >> $HOME/tmp/out 2>&1
and explains further up
The format of a cron command is very much the V7 standard, with a num‐
ber of upward-compatible extensions. Each line has five time and date
fields, followed by a command, followed by a newline character ('\n').
...
field allowed values
----- --------------
minute 0-59
hour 0-23
day of month 1-31
month 1-12 (or names, see below)
day of week 0-7 (0 or 7 is Sun, or use names)
So the command shown by Greg Wooledge runs at 6:25 am the comand
test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
which runs the programs in /etc/cron.daily (by run-parts(8)) if not
/usr/sbin/anacron exists and is executable.
Have a nice day :)
Thomas
Reply to: