#!/bin/bash export MAIN_DIR=/scratch1/parfenov/Soft/TestNodes/sge_ncx export MAIN_SCRIPT=${MAIN_DIR}/start_template.sh export FILELIST=${MAIN_DIR}/nodes.list export NODE=`sed "${TASK_ID}q;d" $FILELIST` export TMP_DIR=${MAIN_DIR}/TMP mkdir -p $TMP while read line do echo "$line" export TMP=${TMP_DIR}/TMP_${line} mkdir -p $TMP sed\ -e 's!@jobnode@!'$line'!g'\ $MAIN_SCRIPT > ${TMP}/start.sh qsub -t 1-1 ${TMP}/start.sh sleep 10s done < $FILELIST