running a batch file in loop


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting running a batch file in loop
# 1  
Old 05-21-2008
running a batch file in loop

i have a batch file which should run every five min...for an hour
can any one help me out
# 2  
Old 05-21-2008
You have crontab for that.. Check it.. Sample entry is

Code:
 /5 * * * * yourCommandFile.ksh

By the way /5 means every 5 mins, other wise you can add 00, 05, 10, 15, 20, 25, 30, 35, 40 , 45, 50, 55 * * * * yourCommandFile.ksh

Last edited by guruparan18; 05-21-2008 at 03:12 AM.. Reason: Explained /5
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Windows & DOS: Issues & Discussions

Loop statement within a batch script

I have to create a couple of files within a directory structure. Filename stays the same, but at the end of each file, the number appears. Example: File needs to be created within directory c:\temp File Name will stay the same (testfile), but extension will increase, starting at 01 - example... (1 Reply)
Discussion started by: HenkTrumpie
1 Replies

2. Shell Programming and Scripting

Test if Remote server is up and running before SFTP'ing files (in batch mode)

Hello, In our Data Warehouse environment, before our batch SFTP jobs kick off to pull the files from remote servers, I would like to setup a pre-sftp job that would test if all the remote servers from where the files are being pulled, are up and running. If any one of the remote serer is... (2 Replies)
Discussion started by: Dippu
2 Replies

3. Windows & DOS: Issues & Discussions

Batch file loop and increment value for condition

I am trying to have the below batch file do following two things: 1. only allow the values YES,yes,Y,y, or NO,no,N,n 2. increment the counter %var1 only if answer to question 2 is "y" and not able to get the syntax correct. If %var1%=1 then I am trying to display function :end. Thank you :).... (0 Replies)
Discussion started by: cmccabe
0 Replies

4. Shell Programming and Scripting

Running ffmpeg in loop seems to change reading from file

Hi everyone, I am fairly new to shell scripting. I want to read in numbers from a file (one number per line). This works perfectly fine while read CurrentLine do echo $CurrentLine done < myfile and yields the correct output: 272 745 123 If I however run a ffmpeg... (2 Replies)
Discussion started by: Thriceguy
2 Replies

5. Shell Programming and Scripting

While Loop not running

echo "The recreate was successfully completed for device file $LCL_CLN_FILE." >> $LOG_FILE remaining=$(symclone -sid $LCL_SID -f $ETC/$LCL_CLN_FILE query | grep MB | awk '{print $2}') if then while do echo "$remaining MB's to be copied........." >> $LOG_FILE ... (10 Replies)
Discussion started by: rajsan
10 Replies

6. UNIX for Dummies Questions & Answers

Unix Batch command, and running jobs in queues.

Hello all, I have a quick question. I work in a computational science laboratory, and we recently got a few mac pros to do molecular optimizations on. However, on our normal supercomputers, there are queue systems, mainly PBS. Anyway, the macs obviously don't have PBS, but I've read about... (0 Replies)
Discussion started by: corrado33
0 Replies

7. Shell Programming and Scripting

Running a BATCH script from my korn script with multiparameters

I've this BATCH script to run from my korn script... The command is /usr/local/BATCH/runBatch.sh PARAM1 'PARAM2 -PARAM21 PARAM22' (runBatch takes parameter 1 = PARAM1 parameter 2 = 'PARAM2 -PARAM21 PARAM22' ) If i run this command from command line it just runs fine... ... (7 Replies)
Discussion started by: prash184u
7 Replies

8. Shell Programming and Scripting

SSH in batch mode and File-Handles in a loop

Hi all I try to execute SSH commands on several hosts in a while-loop. There seems to be a problem with file-handle, first cycle works correct but no other one will follow due to the while condition is false even that there are many more host entries (lines) in all_hosts.dat. ... (3 Replies)
Discussion started by: DaveCutler
3 Replies

9. Shell Programming and Scripting

Running shell scripts automatically without using Batch or at commands

I have been trying to run a unix script which contains many sql statements.I need to run this script every monday morning. I tried to run on command prompt, it works fine. But while I run it via batch or at command., it returns with library module could not be loaded (libcompat.1.o could not be... (3 Replies)
Discussion started by: ritzwan0
3 Replies

10. Shell Programming and Scripting

batch file not running after implement dummy shell

Hi, I want to ask if anyone has any ideas, why the batch file i created to transfer files on my desktop doesn't run after i put this line in /etc/passwd and any idea to overcome it ? Thanks user:!:xxx:xxx::/home/user:/usr/local/bin/ssh-dummy-shell (2 Replies)
Discussion started by: DarReNz
2 Replies
Login or Register to Ask a Question