The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

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 -->
  #4 (permalink)  
Old 02-10-2009
scorpio scorpio is offline
Registered User
  
 

Join Date: Apr 2008
Posts: 41
Hi,

Try something like this...( i have not tested this code)

#!/bin/sh

./Set1.sh &
process_id_set1=`ps -ef | grep ora_q001_DM2XDB | grep -v grep | awk '{print $2}'`
./Set2.sh &
process_id_set2=`ps -ef | grep ora_q001_DM2XDB | grep -v grep | awk '{print $2}'`
./Set3.sh &
process_id_set3=`ps -ef | grep ora_q001_DM2XDB | grep -v grep | awk '{print $2}'`

wait process_id_set1
echo "Set1 Completed -- now start Set4"
./Set4.sh &

wait process_id_set2
echo "Set2 Completed -- now start Set5"
./Set5.sh &




Regards,