The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Operating Systems > SUN Solaris
.
google unix.com



SUN Solaris The Solaris Operating System, usually known simply as Solaris, is a free Unix-based operating system introduced by Sun Microsystems .

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Schedule to run every 3 minutes - CRONTAB prashanth_gs SUN Solaris 4 02-20-2007 07:52 AM
schedule many jobs using cron sireesha15 UNIX for Dummies Questions & Answers 1 11-28-2006 11:20 PM
How to schedule a job ashvik UNIX for Advanced & Expert Users 5 09-22-2005 07:53 AM
How can I schedule a script on Solaris? krikets Shell Programming and Scripting 3 10-06-2003 09:29 AM
schedule dial-out different ISP's Hansaplast UNIX for Dummies Questions & Answers 2 01-15-2002 03:23 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 12-01-2006
prashanth_gs prashanth_gs is offline
Registered User
  
 

Join Date: Dec 2006
Posts: 25
Crontab Job - Schedule

Hi all,

I scheduled daily export backup script in my crontab on yesterday.
Today I noticed that the daily export doesnt occured.

More, while issuing command crontab -l I am not finding any scheduled jobs which I scheduled.

As this is new server, I executed following commands to schedule a job yday.

export EDITOR=vi
crontab -e

30 21 * * * /u07/backupscripts/dailyexp10g.sh

Today:
$ crontab -l
$

Nothing was there.

What is the problem and How I has to fix it?

Please advice.

Prashanth.g.s.
  #2 (permalink)  
Old 12-01-2006
duke0001 duke0001 is offline
Registered User
  
 

Join Date: Nov 2005
Posts: 131
You type crontab -e, it open editor to edit crontab. After you enter your crontab line, you need to type shift: wq to save your editing line. Then crontab will take action. It seems that you didn't save crontab file. The crontab didn't take any action. Try again.

Last edited by duke0001; 12-01-2006 at 10:54 PM..
  #3 (permalink)  
Old 12-01-2006
Tornado's Avatar
Tornado Tornado is offline Forum Advisor  
Registered User
  
 

Join Date: Nov 2006
Location: Melbourne
Posts: 249
Or you ran crontab as a different user..

Its not ctrl: its just : which is shift; I normally use shift; x
  #4 (permalink)  
Old 12-01-2006
duke0001 duke0001 is offline
Registered User
  
 

Join Date: Nov 2005
Posts: 131
Tornado:

Thanks. That was typo. It should be: "shift: wq" to save file if you use vi editor.
  #5 (permalink)  
Old 12-02-2006
prashanth_gs prashanth_gs is offline
Registered User
  
 

Join Date: Dec 2006
Posts: 25
No, I saved it properly. Bcoz I saw lot of times after scheduling the job.

crontab -l
  #6 (permalink)  
Old 12-02-2006
Tornado's Avatar
Tornado Tornado is offline Forum Advisor  
Registered User
  
 

Join Date: Nov 2006
Location: Melbourne
Posts: 249
Well if you did save it correctly and you saw the entry in your crontab then either 1) someone has removed it or 2) you ran crontab -l as a different user

To make sure it isn't under another users crontab run this:
Code:
grep backupscripts /var/spool/cron/crontabs/*
I have never heard of any bugs or problems with cron entries dissapearing.
  #7 (permalink)  
Old 12-04-2006
prashanth_gs prashanth_gs is offline
Registered User
  
 

Join Date: Dec 2006
Posts: 25
Hi

I am getting the output while executing the follow script.

1.
$ grep backupscripts /var/spool/cron/crontabs/*
grep: can't open /var/spool/cron/crontabs/oracle
grep: can't open /var/spool/cron/crontabs/oracle10
grep: can't open /var/spool/cron/crontabs/oracleas
grep: can't open /var/spool/cron/crontabs/root
grep: can't open /var/spool/cron/crontabs/sys
grep: can't open /var/spool/cron/crontabs/uucp

2. $ crontab -l oracle10 ----> user name
$


3. cd /var/spool/cron/crontabs

$ ls -lrt

-r--r--r-- 1 root root 750 Jan 9 2006 lp
-rw-r--r-- 1 root sys 190 Jan 9 2006 adm
-r-------- 1 root uucp 404 Jan 9 2006 uucp
-r-------- 1 root sys 1014 Jan 10 2006 sys
-r-------- 1 root oinstall 33 Jul 11 16:58 oracleas
-r-------- 1 root other 1799 Nov 27 14:39 root
-r-------- 1 root oinstall 244 Nov 30 17:26 oracle
-r-------- 1 root dba 0 Dec 1 15:02 oracle10

Is there anythging wrong from myside?

Please advice.

Prashanth
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 09:35 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language translation by Google.
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0