#!/bin/bash -f # #---------------- SHORT COMMENT ---------------------------------------- # '-f' means don't source .bashrc # Template script for parallel MPI jobs to run on mphase Grid Engine cluster. # Modify it for your case and submit to Grid Engine with # command "qsub mpi_run.sh". # ------Attention: #$ is a special SGE symbol, not a comment ----- # # The name, which will identify your job in the queue system #$ -N MPI_Job # # Parallel environment and CPU number #$ -pe mpich 2-4 # --------------------------- # Start the job in the current working directory #$ -cwd # Specify files for the standart output and error #$ -o MPI-stdo.output #$ -e MPI-stderr.output # Specify MPIR_HOME from submitting environment. #$ -v MPIR_HOME=/usr/local/mpich2_smpd # --------------------------- export MPIEXEC_RSH=rsh echo "Got $NSLOTS slots." # Put the name of your compiled MPI file, for example, "cpi" myjob=$HOME/cpi.x $MPIR_HOME/bin/mpiexec -rsh -nopm -n $NSLOTS -machinefile $TMPDIR/machines $myjob exit 0 |
![]() | ![]() | ![]() |