Im trying to run a multiple instance job from a script.
The job instances should run parallely .
So to test it I developed a simple sequence job(Multiple Instance) with Only job activity stage .Its underlying parallel job(Also multiple Instance) reads from a sequential file and writes it to another file.
To trigger them parallely im using the script as below.Its running fine, but wanted to check it its a right way to do it.
Code: Select all
#!bin/bash
dshome='/opt/app/ibm/InformationServer/V87/Server/DSEngine'
cd $dshome
. ./dsenv
cd /etl/stage
function calljob {
$dshome/bin/dsjob -authfile /home/logon -run -warn 0 -jobstatus -param Instance_number=$1 prjctname SEQ_MULTIPLE_INSTANCE.$1 &
}
for i in `ls -c1 Read*`
do
echo -e "Starting $1 instance \n`date +%Y%m%d%H%M%S`"
calljob $i &
echo -e "Triggered $1 instance \n`date +%Y%m%d%H%M%S`"
done
wait
This is where i want to be check if its a right way to do it.
Thanks,
Chetan.C