Reputation: 161
I'm trying to submit a torque job that is dependent on an array completing.
FIRST=`qsub -q hep -t 1-5 foo.sh`
qsub -q hep -W depend=afterok:$FIRST bar.sh
The FIRST job array submits and completes just fine but the second job bar.sh just holds indefinitely.
If I remove the array option from the first argument the second job will succeed as planned but this does not really solve the problem.
There was a similar thread from 3 years ago but it seems that there was no actual resolution:
How to wait for a torque job array to complete
Thanks for your help.
Upvotes: 6
Views: 476
Reputation: 161
Found the answer, the depend argument must be afterokarray
. The example below works.
FIRST=`qsub -q hep -t 1-5 foo.sh`
qsub -q hep -W depend=afterokarray:$FIRST bar.sh
Upvotes: 7