The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 04-13-2005
993 993 is offline
Registered User
  
 

Join Date: Apr 2005
Posts: 2
Run Processes Sequentially

I've written two shell scripts where script A calls script B, passing two parameters.

Script B takes about a minute to complete (loading and processing data).

When running script B once from script A, everything works ok. However, when running script B more than once from script A, things start to mess up:

e.g with Script A in the format below, the second run starts before the first run has finished.

ScriptB Param1A Param2A
ScriptB Param1B Param2B

Can anyone advise how I can introduce a check to see if script B has completed before starting it again with new parameters?

For info I'm using hp/ux 11.

I'm new to Unix and new to this forum, so thanks for your help in advance.