#!/bin/bash #SBATCH --cpus-per-task=1 #SBATCH --mem-per-cpu=[MEMORY_NEEDED_FOR_JOB] #SBATCH --partition=[PARTITION/QUEUE] #SBATCH --time=[DAYS]-[HOURS]:[MINUTES]:[SECONDS] #SBATCH --job-name=[JOBNAME] #SBATCH --mail-user=[USERNAME]@memphis.edu #SBATCH --output=[STDOUT].out #SBATCH --error=[STDERR].err ################################################# # [SOMETHING] # #-----------------------------------------------# # Please replace anything in [] brackes with # # what you want. # # Example: # # #SBATCH --partition=[PARTITION/QUEUE] # # Becomes: # # #SBATCH --partition=computeq # ################################################# ################################################# # --partition=[PARTITION/QUEUE] # #-----------------------------------------------# # computeq: 40 cores, 192 GB mem # # shortq: 40 cores, 192 GB mem, 2 day timelimit # # bigmemq: 40 cores, 768-1536 GB mem # # gpuq: 40 cores, 192 GB mem, 2 v100 GPUs # ################################################# # --time=[DAYS]-[HOURS]:[MINUTES]:[SECONDS] # #-----------------------------------------------# # Total time you allocate for your job. It will # # be killed after this time. If you need an # # extension contact hpcadmins@memphis.edu # ################################################# # --account=[DEPTCODE] # #-----------------------------------------------# # Your department code. i.e. chemistry=CHEM # ################################################# # --job-name=[JOBNAME] # #-----------------------------------------------# # Your jobname when you run 'squeue'. # ################################################# # --mail-user=[USERNAME]@memphis.edu # #-----------------------------------------------# # It will mail you with certain statuses. # ################################################# # --mail-type=[MAIL_OPTIONS] # # --output=[STDOUT].out # # --error=[STDERR].err # #-----------------------------------------------# # Run 'man sbatch' to see options. # ################################################# # --mem-per-cpu=[MEMORY_NEEDED_FOR_JOB] # #-----------------------------------------------# # Default is 1024. It is in megabytes (MB). If # # you need more, put it here. If you job fails # # check [STDERR].err to confirm that it was out # # of memory. This is per CPU. # ################################################# ################################################# # SLURM_SUBMIT_DIR # #-----------------------------------------------# # Usually you want to go to the directory # # that 'sbatch slurmSubmitSerial.sh' was called.# # SLURM_SUBMIT_DIR is an environment variable # # that defines that directory. Otherwise, HOME # # is default (/home/[USERNAME]/). # ################################################# cd $SLURM_SUBMIT_DIR ################################################# # modules # #-----------------------------------------------# # Any modules you need can be found with # # 'module avail'. If you compile something with # # a particular compiler using a module, you # # probably want to call that module here. # ################################################# #module load [MODULE] ################################################# # SLURM_JOB_ID # #-----------------------------------------------# # You can use SLURM_JOB_ID environment variable # # to get the current jobId. # #'squeue -u [USERNAME]' lists user jobs with # # jobId in the left column. # ################################################# echo "$SLURM_JOB_ID" ################################################# # Run your executable here # ################################################# #[EXECUTABLE] [OPTIONS]