cron job not getting executed [message #425760] |
Mon, 12 October 2009 02:27 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
ankush_chawla
Messages: 136 Registered: November 2006
|
Senior Member |
|
|
i really wonder why below job not getting executed .
30 01 * * * /u01/home/oracle/sql/histogram.sh >> /u01/home/oracle/sql/histogram.log
40 12 * * * /u01/home/oracle/sql/histogram.sh >> /u01/home/oracle/sql/histogram.log
$ more /u01/home/oracle/sql/histogram.sh
#!/bin/ksh
sqlplus sa/crmggnqa2135 @histogram_table_act_entry.sql
sqlplus sa/crmggnqa2135 @dbms_stats_intall.sql
I have check /var/cron/log but it shows no error
CMD: /u01/home/oracle/sql/histogram.sh >> /u01/home/oracle/sql/histogram.log
> oracle 2795 c Sun Oct 11 12:40:00 2009
However the log file is not present and histogram doesnt get created.
If i execute the histogram.sh manually it gets executed fine with no issue.
Please help
Regards
Ankush
|
|
|
|
Re: cron job not getting executed [message #425763 is a reply to message #425762] |
Mon, 12 October 2009 02:38 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
ThomasG
Messages: 3212 Registered: April 2005 Location: Heilbronn, Germany
|
Senior Member |
|
|
Also, now you only re-direct STDOUT. Try re-directing STDERR also with :
30 01 * * * /u01/home/oracle/sql/histogram.sh 1>>/u01/home/oracle/sql/histogram.log 2>&1
|
|
|
|