[OpenIndiana-discuss] crontab error

Kevin J. Woolley kjw at javabunny.net
Wed Jan 26 21:39:33 UTC 2011


On Wednesday, 26 January, 2011 13:31, "ann kok" <oiyankok at yahoo.ca> said:

> Hi
> 
> I am trying "crontab cron1.txt" and have error as
> 
> root at opensolaris:~/ann# crontab cron1.txt
> 0 0 * * 7 /root/ann/deletelog.sh >/dev/null 2>&1
> crontab: error on previous line; number out of bounds.
> crontab: errors detected in input, no crontab file generated.
> 
> but it is fine in linux. What am I wrong?
> 
> cron1.txt
> * * * * * /root/ann/1.sh >/dev/null 2>&1
> * * * * * /root/ann/2.sh >/dev/null 2>&1
> * * * * * /root/ann/3.sh >/dev/null 2>&1
> 59 23 * * * /root/ann/backup.sh  >/dev/null 2>&1
> 0 0 * * 7 /root/ann/deletelog.sh >/dev/null 2>&1

My first guess is that the '7' is responsible -- that column may be zero-indexed.  Try '6'.

Cheers,

kjw





More information about the OpenIndiana-discuss mailing list