BB Unix Network Monitor - Message
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: {bb} 2nd Tuesday
On Wed, 2006-02-15 at 15:52, Ryan Novosielski wrote:
> Anyone written any elegant script or found any replacement to cron to
> handle the fact that one cannot, without playing games, schedule things
> for X day of X week of the month? It appears as if HP-UX cron treats
> those fields in cron with a logical and, but IRIX treats them as a
> logical or. Seems most other OS' do as well.
That looks to be the POSIX way of doing things.
> Any hints?
Perhaps the simplest solution would be to configure cron to run the
script on the required day of the week. Then it would be possible
to design the script to query the "day of the month" (using the
"date" command, for example) and only function during a suitable
window. Something like:
expr \( `date +%e` - 1 \) / 7 + 1
will give you the "week of the month".
Cheers, Phil.
--
Government lies, and newspapers lie, but in a democracy they are
different lies.
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=-=-=-=
To unsubscribe from this list, or to subscribe to the bb-digest list
send e-mail to mailto:majordomo@bb4.com with unsubscribe bb -and/or-
subscribe bb-digest in the BODY of the message.
Home |
Main Index |
Thread Index