Quote:
Originally Posted by sunpraveen
That is because of the missing statement (highlighted in RED) within the for loop
Code:
for (( i = 1 ; i <= 20 ; i++ ))
do
export SMCHOME=/global/app/R1S1A3/RAFS/RAF_$i
$SMCHOME/bin/genraf.exe &> LOG_RAF/RAF_$i.txt &
i= $(( $i + 1 ))
done
|
No, that's taken care of by the for loop (otherwise there would be a syntax error). I suspect the shell parses the redirection incorrectly. Try writing it like this:
Code:
for (( i = 1 ; i <= 20 ; i++ ))
do
export SMCHOME=/global/app/R1S1A3/RAFS/RAF_$i
${SMCHOME}/bin/genraf.exe > LOG_RAF/RAF_${i}.txt &
done