Solved

IRIX cron, How do I set one up?

Posted on 1997-09-29
11
428 Views
Last Modified: 2013-12-16
Hiya...
I need to set a cron entry for root on an IRIX system.
How do I go about this? I already got my script that I want to run at midnight every day except Saturday. It is to perform an rdump to a Solaris Tape Server.

regards.
0
Comment
Question by:rickyr
  • 5
  • 3
  • 3
11 Comments
 
LVL 84

Expert Comment

by:ozo
Comment Utility
(crontab -l; echo '0 0 * * 0-5       script') | crontab
0
 
LVL 4

Expert Comment

by:jlms
Comment Utility
You can also type
crontab -e
and edit what appears including a line like the suggested in the comment by ozo.
Be sure to set the environmenr variable EDITOR like this Assuming your favorite editor is emacs, if not put vi or whatever you use):
EDITOR=emacs or setenv EDITOR emacs
I dont know how complicated is you script, but if it includes only one dump command you can include this directly in the crontab.
0
 
LVL 84

Expert Comment

by:ozo
Comment Utility
What version of IRIX are we talking about?
crontab -e
works with a sufficiently recent IRIX.
I'd pesonally prefer to edit in any version,
(but then that makes the answer harder to explain:-)
0
 
LVL 4

Expert Comment

by:jlms
Comment Utility
It is IRIX 6.2 ...
0
 
LVL 84

Expert Comment

by:ozo
Comment Utility
jlms, I'm curious, how did you determine that? I don't see how to tell from the question.
Did rickyr mention it in a previous question?
Or have you had personal contact with rickyr?
0
Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

 
LVL 3

Author Comment

by:rickyr
Comment Utility
Hiya jlms...
Sorry, I should have said that I got IRIX 5.3. I tried what you said....
# crontab -e
      usage is:
      crontab [ file | -l -r ]
also tried...
# crontab root
      usage is:
      crontab [ file | -l -r ]
also tried...
# crontab root -l
      usage is:
      crontab [ file | -l -r ]

The script does the following....
for i in dumpvol1 dumpvol2
do
rdump......etc
done

regard
0
 
LVL 4

Expert Comment

by:jlms
Comment Utility
Then the comment of ozo should be the right answer! Did you try it?
0
 
LVL 84

Expert Comment

by:ozo
Comment Utility
`man crontab` could tell you even more about the usage
But even in absence of a -e flag, I think I'd prefer to edit:

su
emacs /var/spool/cron/crontabs/root
crontab /var/spool/cron/crontabs/root
crontab -l
0
 
LVL 3

Author Comment

by:rickyr
Comment Utility
Hiya....
I did

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

the last bit was from ozo's comment,
so you can come back for your points.

regards
0
 
LVL 84

Accepted Solution

by:
ozo earned 40 total points
Comment Utility
#crontab -l > root.cron
#vi root.cron
--->edit file here<---
#crontab root.cron
0
 
LVL 3

Author Comment

by:rickyr
Comment Utility
Hiya...

You're original comment was the one that
put me in the right direction as to how IRIX handles cron entries.

Thanks for your time ozo! yours too jlms.

regards
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

744 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

16 Experts available now in Live!

Get 1:1 Help Now