Sure. Post the cron line you're using. Please use code tags when posting codes on daniweb:
[code=text]
...cron here...
[/code]
sknake
Industrious Poster
4,954 posts since Feb 2009
Reputation Points: 1,764
Solved Threads: 735
Does that ever run? I would put your evaluation in an external script and call that script from cron.
Install this in your crontab:
0 0 0 * 1 ksh /u/dolfin/bin/run_avg_cogs_datetest.sh
Then create the new file run_avg_cogs_datetest.sh :
#! /usr/bin/ksh
day=$(date +%d)
if ((day <= 7)) ; then
exec /u/dolfin/bin/run_avg_cogs.sh >> /u/dolfin/log/run_avg_cogs.LOG 2>&1
fi
exit 1
The cron job runs every every monday of the month, but your script only executes if its within the first 7 days of the month. So effectively the first monday of every month.
Borrowed from: http://www.unix.com/unix-dummies-questions-answers/2551-crontab-first-monday-month-only.html
sknake
Industrious Poster
4,954 posts since Feb 2009
Reputation Points: 1,764
Solved Threads: 735