#!/bin/bash # # Developed by WIKKI BRASIL LTDA (2020) # Some simulation parameters *** THE USER CAN CHANGE THIS SECTION # *************************************************************** # # Number of processors - for example nodes=2:ppn=12, for 24 procs, two nodes with 12 procs #SBATCH --nodes=1 # Nodes number #SBATCH --ntasks-per-node=2 # Tasks per node #SBATCH --cpus-per-task=1 # Threads number # # #SBATCH --exclusive #Exclusive use of nodes during the job execution # Define the name of the job, for example, myCase #SBATCH --job-name=01K9W50ZGRMWA5TKG4TMGSSWSP # # #SBATCH --mail-type=END,FAIL # Mail events (NONE, BEGIN, END, FAIL, ALL) # #SBATCH --mail-user=your@email.address # Where to send mail. Set this to your email address # Example: # #SBATCH --mail-user=antonio.samel@wikki.com.br # # Uncomment lines below if you want to change default values # # #SBATCH --mem-per-cpu=2048mb # memory to be used for each process # #SBATCH --time=6:00:00 # total walltime time for the job # # Specify the queue to be used: "blue","green", "red". Lets OF be green # # #SBATCH --partition=green #queue to be used or # #SBATCH -p gpu #queue to be used #SBATCH --partition=batch #queue to be used # # Project/Account #SBATCH --account=none # or # #SBATCH -A none # # *************************************************************** # Set your job output file, for example, myCaseLog #SBATCH --output=jid_%j.qout # # Set your job error file #SBATCH --error=jid_%j.qerr # # Load enviroment variables, use submission environment #SBATCH --export=ALL # --export=NONE to not export environment # Solver and Case to be simulated *** ADAPT FOR YOUR CASE!! # ************************************************************************* SOLVER=./runCase WORK_DIR=/mnt/efs/volume/simulations/joao.marchori/01K9W50ZGRMWA5TKG4TMGSSWSP # ###### DO NOT MAKE CHANGES FROM HERE ################################### # Check if directory exists if [ -d $WORK_DIR ]; then echo "RUN directory $WORK_DIR is ok, go for it!!" else echo "The RUN directory was not found: $WORK_DIR does not exist!" exit 0 fi # Load user environment variables source ~/.bashrc echo ------------------------------------------------------ echo 'This job is allocated on '${SLURM_NTASKS}' cpu(s)' echo 'Number of Nodes Allocated = '${SLURM_JOB_NUM_NODES}'' echo 'Number of Tasks Allocated = '${SLURM_NTASKS}'' echo 'Number of Cores/Task Allocated = '${SLURM_CPUS_PER_TASK}'' echo 'Job is running on node(s): ' scontrol show hostnames $SLURM_JOB_NODELIST echo ------------------------------------------------------ # Go to the case directory and run de case cd $WORK_DIR echo -e "\n## Job started at $(date +'%d-%m-%Y as %T') #####################\n" ## Informacoes do job impressos no arquivo de saida. echo -e "\n## Active Jobs for $USER: " squeue -a -u $USER echo -e "## Node for job execution (hostname): $(hostname -s)" echo -e "## Number of task for this job: $SLURM_NTASKS" echo -e "## Working Directory = $(pwd)" $SOLVER > ./caseExecution_${SLURM_JOBID}.qout #sh ../post_script.sh $WORK_DIR