0

I am new to programming. I want to submit two .slurm files using a bash script. The two for loops should submit two separate jobs. I want to submit the second for a loop once the first one is completed. Appreciate you help

rm -r slurm-*.out
for i in `seq 1 1`; do
        sbatch production.slurm
done &&
sleep 10

for i in 'seq 1 1'; do
        sbatch run20.slurm
done
oguz ismail
  • 1
  • 16
  • 47
  • 69
  • [How do I format my code blocks?](https://meta.stackexchange.com/questions/22186/how-do-i-format-my-code-blocks) – Cyrus Nov 02 '19 at 13:56
  • I don't quite understand what you are trying to do... Why having for loops if it is for one iteration? what is wrong with your code? – OznOg Nov 02 '19 at 15:18
  • 1
    [How to hold up a script until a slurm job (start with srun) is completely finished?](https://stackoverflow.com/questions/46427148/how-to-hold-up-a-script-until-a-slurm-job-start-with-srun-is-completely-finish) – KamilCuk Nov 02 '19 at 15:20

0 Answers0