Creating cronjob


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Creating cronjob
# 1  
Old 06-23-2014
Creating cronjob

Guys

I am a complete newbie to UNIX and I need some help. My team has taken on support of a very old UNIX box which is running version 2.4.21. I need to create an urgent cronjob to restart the sladp process every sunday at 1am. This is to to provide a temp fix to a production issue. Problem I have is im not sure of the syntax for this in the older versions.

would this work

1 0 * * 0 service slapd stop;service slapd start >/opt/gw/ds5.2/slapd-test-ldap-ty/tmp/restart-status
# 2  
Old 06-23-2014
Creating cronjob

Hi,
try this
0 1 * * 0 [your script] >[log_file]

it triggers the mentioned script every sunday at 1 AM.

<OR>
@weekly [your script] >[log_file]

This will trigger the script every sunday @00:00 AM

I am also new to unix. If anything wrong in above commands please correct me,
gud luck Smilie

Thanks,
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Homework & Coursework Questions

Creating a .profile, displaying system variables, and creating an alias

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Here is what I am supposed to do, word for word from my assignment page: 1. Create/modify and print a... (2 Replies)
Discussion started by: Jagst3r21
2 Replies

2. UNIX for Dummies Questions & Answers

cronjob

Is the cronjob below can run only first wednesday of every month? 30 5 1-7 * 3 command please tell me (3 Replies)
Discussion started by: Anjan1
3 Replies

3. Solaris

Creating Cronjob using .sh file

Hi all, I have created .sh file which contains oracle's export command to export the tables for backup. Also, used crontab for scheduling the above. currently, cronjob is defined manually using crontab -e command from the root user, but want to know how to write a shell script which on... (2 Replies)
Discussion started by: milink
2 Replies

4. UNIX for Dummies Questions & Answers

how to cancel a cronjob if the cronjob still running

hi everyone I'm newbie in this forum hope I can get some help here :) I have a command in crontab that executed every 1 minute sometime this command need more than 1 minute to finish the problem is, the crontab execute this command although it's not finish processing yet and causing the system... (7 Replies)
Discussion started by: 2j4h
7 Replies

5. AIX

cronjob

Hi, I want to schedule a script on daily basis in morning 8:00 A.M and 5:00 P.M , how can i achieve this, i want the parameter 0 ? * * * what will be the second parameter in my case. Regards (1 Reply)
Discussion started by: maooah
1 Replies

6. Shell Programming and Scripting

help needed with creating challenging bash script with creating directories

Hi, Can someone help me with creating a bash shell script. I need to create a script that gets a positive number n as an argument. The script must create n directories in the current directory with names like map_1, map_2 etcetera. Each directory must be contained within its predecessor. So... (7 Replies)
Discussion started by: I-1
7 Replies

7. Solaris

Creating a CronJob Script

Hi All, Good Day. Anyone can guide me on how to create a cronjob script that run prstat -a and vmstat 10 10 on the certain time of the day and produce a log which will be kept in a specific directory? I am running on Solaris 10. Thanks. (2 Replies)
Discussion started by: ronny_nch
2 Replies

8. UNIX for Dummies Questions & Answers

cronjob

hi iam new at unix.iam running a cronjob,which i want to run on the first day of every month at 1AM.this is what i have specified: 00 01 1 * * is this corect? (1 Reply)
Discussion started by: wiz83
1 Replies

9. HP-UX

CronJob

Dear Guru, I have submitted some cronjobs that has been running for quite sometimes. However, today I counter some cronjob did not run. Can you please explain what causes this to happen. Any system setting that limit number of cronjob per minutes to be started, etc? Thanks. Kelly (1 Reply)
Discussion started by: hcng08
1 Replies

10. Shell Programming and Scripting

Cronjob

Please can someone help me. I need to set up a cron job to measure CPU usage, Disk I/O and memory usage over a period of 1 minute along with the number of users logged into the system. I also need to send it to another user besides myself every hour. Please can someone help me! Thanks. (4 Replies)
Discussion started by: gerwhelan
4 Replies
Login or Register to Ask a Question