wait / sleep what to use???


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers wait / sleep what to use???
# 1  
Old 09-19-2006
wait / sleep what to use???

Hi

I have a script, where i need to execute the follwoing scripts/commands in my script. but those should be executed one by one

cd /aa/205/jams
.cmd/mass_all.sh - -> execution of this will take atleast 20-30mins
cd $HOME/precompile
ant-Ddir.location=$HOME/tomcat/webapps - -> execution of this will take atleast 20-30mins
cd /dist
ant-Ddir.location=advance-Drelease=2.0.5 -Ddir.base=$HOME - - ->execution of this will take atleast 20-30mins

how do i mange all of these in the script...

Any idea can some one....tell me what i need to use..
# 2  
Old 09-19-2006
Quote:
Originally Posted by gkrishnag
Hi

I have a script, where i need to execute the follwoing scripts/commands in my script. but those should be executed one by one

cd /aa/205/jams
.cmd/mass_all.sh - -> execution of this will take atleast 20-30mins
wait
cd $HOME/precompile
ant-Ddir.location=$HOME/tomcat/webapps - -> execution of this will take atleast 20-30mins
wait
cd /dist
ant-Ddir.location=advance-Drelease=2.0.5 -Ddir.base=$HOME - - ->execution of this will take atleast 20-30mins

how do i mange all of these in the script...

Any idea can some one....tell me what i need to use..
That should do it
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Sleep while i > 0

Hi, I have a script that runs a process at the beginning and I want to sleep/wait until this process is finished and then continue with the rest of the script. I am trying with this, but it is not working: process=`ps -ef | grep "proc_p01 -c" | grep -v grep | wc -l` if ; do sleep 10 done... (7 Replies)
Discussion started by: apenkov
7 Replies

2. Shell Programming and Scripting

calling a shell script in background and wait using "wait" in while loop

Hi, I am facing a strange issue, when i call a script from my while loop in background it doesnt go in background, despite the wait i put below the whil loop it goes forward even before the process put in background is completed. cat abc.txt | while read -u4 line do #if line contains #... (2 Replies)
Discussion started by: mihirvora16
2 Replies

3. Shell Programming and Scripting

Wrapping 'sleep' with my 'resleep' function (Resettable sleep)

This is a very crude attempt in Bash at something that I needed but didn't seem to find in the 'sleep' command. However, I would like to be able to do it without the need for the temp file. Please go easy on me if this is already possible in some other way: How many times have you used the... (5 Replies)
Discussion started by: deckard
5 Replies

4. UNIX for Dummies Questions & Answers

How can i use fork,sleep,wait and write in a process with father and son..??

Hi.. I was unable to do (gcc code) which refers to the fork,wait,sleep and write.. what i want to do: A process of father create (fork) a son and will sleep 90 seconds..After this, son process create a grandchild and will sleep 60 seconds..Grandchild process will sleep for 30 seconds..After... (3 Replies)
Discussion started by: gumlucin
3 Replies

5. Shell Programming and Scripting

help in wait or sleep command

Hi All, I have a script which runs 3 scripts. The first script creates two files. The other two scripts should run only when the files are created. I tried the following for loop , but it is not working. Can someone please help me. while ; do # Sleep until file does exists/is created... (4 Replies)
Discussion started by: nua7
4 Replies

6. Shell Programming and Scripting

wait command - cat it wait for not-chile process?

Did not use 'wait' yet. How I understand by now the wait works only for child processes, started background. Is there any other way to watch completion of any, not related process (at least, a process, owned by the same user?) I need to start a background process, witch will be waiting... (2 Replies)
Discussion started by: alex_5161
2 Replies

7. Shell Programming and Scripting

Need to execute 2 scripts, wait, execute 2 more wait, till end of file

:cool: I need to execute a shell script to do the following: cat a file run two back ground processes using the first two values from the file wait till those background processes finish run two more background processes using the next two values from the file wait till those background... (1 Reply)
Discussion started by: halo98
1 Replies

8. UNIX for Dummies Questions & Answers

Sleep less than 1 second

Does anyone know a way to sleep less than 1 second? Sometimes when I write scripts that iterates a loop many times it would be nice to slow things down, but sometimes 1 second is too much. (9 Replies)
Discussion started by: bjorno
9 Replies

9. Shell Programming and Scripting

Sleep under one second

If I want a script to sleep for less than a second, would I use a decimal? In other words, if I wanted my script to sleep for 1/4 of a second, would I say, SLEEP .25 ?? (5 Replies)
Discussion started by: Scoogie
5 Replies
Login or Register to Ask a Question