Solved

crontab

Posted on 1997-12-03
5
467 Views
Last Modified: 2013-12-26
Shalom.


Maybe you can tu help me about the following question:

I have user and him name is alex, this user writed aplication "getNews".- This aplication is under
/net/bio/APPS/getNews.-
The him classpath is: CLASSPATH=/usr/java/classes:/usr/local/weblogic/classes:/usr/people/alex/
java/classes:,:/usr/local/weblogic/lib/irix/oracle:/net/apps/classes.

I need tu run this aplication per day, for that I wanted to put in the crontab, so!I put there but
don't receive answer.-

My expresion in the crontab is the following:
0 4 * * */sbin/sh/usr/people/alex/getnews.sh >/usr/people/alex/getnews.log
--------------------------------------------------------------------
My question about that is: Maybe not working because I created this crontab as root but with
shells of alex.?-
or maybe didn't create correct this crontab, or I need to put him classpath to my env?
----------------------------------------
Please If you have any solution for me, you could to sent to me e-mail

thanks
0
Comment
Question by:rachel1
  • 2
  • 2
5 Comments
 

Author Comment

by:rachel1
Comment Utility
Edited text of question
0
 
LVL 1

Expert Comment

by:dhughes111797
Comment Utility
Is there anything in the root mailbox? Usually, if there is
a problem with a cronjob, the owner of the job will get mail.
If you want to put the cronjob under the alex account, you
can use crontab -e alex
0
 
LVL 1

Expert Comment

by:dhughes111797
Comment Utility
Is there anything in the root mailbox? Usually, if there is
a problem with a cronjob, the owner of the job will get mail.
If you want to put the cronjob under the alex account, you
can use crontab -e alex
0
 
LVL 3

Expert Comment

by:rickyr
Comment Utility
Hi...

What OS and Hardware you got? Did you edit the file directly with vi? You can't do this in Solaris, as cron only recognises crontabs that have been edited with the crontab utility, in the Bourne Shell it's......

#> EDITOR=vi
#> export EDITOR
#> crontab -e "user Name"

I don't know what type of UNIX you have, but maybe you can work out the equivalent for your OS. The users crontab will run programs as that user, but only that user can edit his own crontab file, unless of course you are root. Then when you initialise the users crontab it will run with his permissions. As a general rule, I always su to that user, then edit the crontab. That way you cant accidently edit the wrong one.

regards
0
 
LVL 3

Accepted Solution

by:
rickyr earned 50 total points
Comment Utility
Hiya...
I just noticed that you have irix in a pathname, so I'll asume that you are running irix. I have done this in the past

#crontab -l > root.cron
#vi root.cron
--->edit file here<---
#cat root.cron | crontab

regards
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video discusses moving either the default database or any database to a new volume.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now