#!/bin/bash #PBS -S /bin/bash # Job script to run simple mpi job in parallel on 2 nodes # set default resource requirements for job (2 processors on 1 node for 1 hours) # - these can be overridden on the qsub command line #PBS -l nodes=2:ppn=8 #PBS -l walltime=01:00:00 #Change to directory from which job was submitted cd $PBS_O_WORKDIR # load openmpi module so that we find the mpirun command module load openmpi # Run matmul executable in parallel over number of processors requested # by job (2 by default in #PBS line above), output messages go to output_file mpirun matmul > output_file