UNIX for Advanced & Expert Users

Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

crontab not working

👤 Login to reply

 
Thread Tools Search this Thread Display Modes
    #1  
Old 10-17-2008
rajesh_hv rajesh_hv is offline
Registered User
 
Join Date: Oct 2008
Last Activity: 17 October 2008, 7:00 AM EDT
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
crontab not working

Dear all


We have SunOS 5.10 Generic_127127-11 sun4u sparc SUNW,Sun-Fire-V250

i have scheduled cronjob but its not working


Crontab details

15 15 * * * /d5/oratest/testdb/hotbackup_new.sh TEST247
15 15 * * * mkdir -p rajesh /d4/appltest

Crontab log details

> CMD: mkdir -p rajesh /d4/appltest
> root 990 c Fri Oct 17 14:10:00 2008
< root 990 c Fri Oct 17 14:10:00 2008 rc=2
> CMD: /d5/oratest/testdb/hotbackup_new.sh TEST247
> root 1130 c Fri Oct 17 15:15:00 2008
> CMD: mkdir -p rajesh /d4/appltest
> root 1131 c Fri Oct 17 15:15:00 2008
< root 1131 c Fri Oct 17 15:15:00 2008 rc=2
< root 1130 c Fri Oct 17 15:15:00 2008 rc=1
~
Sponsored Links
    #2  
Old 10-17-2008
zaxxon's Unix or Linux Image
zaxxon zaxxon is offline Forum Staff  
code tag tagger
 
Join Date: Sep 2007
Last Activity: 6 July 2018, 8:04 AM EDT
Location: St. Gallen, Switzerland
Posts: 6,574
Thanks: 178
Thanked 569 Times in 483 Posts
If you use the search function, you will get a lot of stuff about people having problems with cronjobs and also there is this FAQ:

https://www.unix.com/answers-frequent...n-crontab.html

https://www.unix.com/unix-dummies-que...-cron-job.html


- Redirect it's output to a file
- Source the .profile or any environment defining file
- Use absolute paths
- Put it into a script maybe
- Read the FAQ
Sponsored Links
    #3  
Old 10-27-2008
jacco jacco is offline
Registered User
 
Join Date: May 2008
Last Activity: 13 November 2008, 10:32 AM EST
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Are the commandlines working correctly when using them from the commandline?
    #4  
Old 10-28-2008
methyl methyl is offline
Registered User
 
Join Date: Mar 2008
Last Activity: 8 June 2016, 9:58 PM EDT
Posts: 6,402
Thanks: 288
Thanked 676 Times in 645 Posts
Look in root mail for any error message from your cron.
BTW. Unusual to run an Oracle process from user root.
Sponsored Links
    #5  
Old 10-28-2008
methyl methyl is offline
Registered User
 
Join Date: Mar 2008
Last Activity: 8 June 2016, 9:58 PM EDT
Posts: 6,402
Thanks: 288
Thanked 676 Times in 645 Posts
The mkdir command looks suspect. The "-p" parameter just tells mkdir to create intermittent directories. As stated the command will create two directories: "rajesh" under root's home directory; and "/d4/appltest" .

In your example both your crons are set for the same time which may give you a problem sequencing the tasks. However the times in your cron log do not match the crontab described.
Sponsored Links
👤 Login to reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
crontab not working isaacniu Solaris 6 01-09-2012 05:41 PM
crontab is not working!! getrue Red Hat 14 09-08-2011 11:06 AM
crontab not working shifahim UNIX for Dummies Questions & Answers 8 08-16-2011 08:22 AM
crontab not working lg123 UNIX for Dummies Questions & Answers 2 04-24-2011 03:47 PM
crontab not working right kymberm UNIX for Dummies Questions & Answers 3 07-09-2003 04:21 PM



All times are GMT -4. The time now is 11:51 PM.

Unix & Linux Forums Content Copyrightę1993-2018. All Rights Reserved.
×
UNIX.COM Login
Username:
Password:  
Show Password





Not a Forum Member?
Forgot Password?