?
Solved

crontab

Posted on 1997-12-03
5
Medium Priority
?
495 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
ID: 1295729
Edited text of question
0
 
LVL 1

Expert Comment

by:dhughes111797
ID: 1295730
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
ID: 1295731
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
ID: 1295732
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 100 total points
ID: 1295733
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

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
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.
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses

862 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