complex crontab query
Matthew Hunt
mph at astro.caltech.edu
Tue Sep 30 14:00:42 PDT 2003
On Tue, Sep 30, 2003 at 10:56:20PM +0200, Kai Grossjohann wrote:
> My understanding is that putting more than one condition in it
> performs a logical conjunction. So wouldn't it work to do like this?
>
> # minute hour dom month dow command
> 0 3 1-7 * 4 mycommand
I thought that might be the case, but the man page says:
# Commands are executed by cron(8) when the minute, hour, and month of
# year fields match the current time, and when at least one of the two
# day fields (day of month, or day of week) matches the current time
# (see ``Note'' below).
...
# Note: The day of a command's execution can be specified by two fields
# -- day of month, and day of week. If both fields are restricted (ie,
# aren't *), the command will be run when either field matches the
# current time. For example, ``30 4 1,15 * 5'' would cause a command
# to be run at 4:30 am on the 1st and 15th of each month, plus every
# Friday.
--
Matthew Hunt <mph at astro.caltech.edu> * Salvage, like other forms of virtue, is
http://www.pobox.com/~mph/ * its own reward. -George Reamerstaff
More information about the freebsd-questions
mailing list