5

I am trying to send an sbatch file to run a code in 200 cores in the system. My code is

#!/bin/sh

#SBATCH --job-name=sm #Job name
#SBATCH --mail-type=ALL # Mail events (NONE, BEGIN, END, FAIL, ALL)
#SBATCH --mail-user=sankalpmathur@ufl.edu # Where to send mail  
#SBATCH --mem-per-cpu=3gb # Per processor memory
#SBATCH --array=1-200
#SBATCH -t 199:00:00    # Walltime
#SBATCH -o output_%a.out    # Name output file 
#
pwd; hostname; date
module load stata
stata-mp -b do array_${SLURM_ARRAY_TASK_ID}.do

When I run the file I get this error

 sbatch HS8_main.sbatch
sbatch: error: Unable to open file HS8_main.sbatch

I have run the same sbatch before and it ran fine. What could possibly be the reason for it to not run this time?

Thank you

Sankalp Mathur
  • 119
  • 1
  • 5

1 Answers1

4

That's the error one gets when the sbatch script isn't in the current directory, or the name is wrong. Are you sure HS8_main.sbatch is the name of your script, and it's in the same place you're running sbatch from?

ciaron
  • 1,089
  • 7
  • 15