Example Scripts
Three sample job scripts are included, one simple example one using the --use-job-scheduler option and two examples for using SGI MPT.
Script 1
#!/bin/bash
#
# Simple example for a job script for using Feko with a queuing system
# like Altair PBS Professional with the automatic Intel MPI integration.
#
#-------------------------------------------------------------
# General settings for Altair PBS Professional
#PBS -l select=2:ncpus=1
#PBS -l walltime=1:30:00
#PBS -q workq
#PBS -V
# General settings for the Feko job
# Name of the Feko file (without extension)
fekname=xxxxx
# Name of the working directory
workdir=/scratch
#-------------------------------------------------------------
echo "=================================================="
echo "Feko running with file " $fekname "
echo "=================================================="
# Go to the correct working directory (where we expect the input file)
cd $workdir
# Start the parallel Feko job
/opt/feko/bin/runfeko $fekname --use-job-scheduler
echo "---"
echo "Feko run finished"
# The end
exit 0
Script 2
#!/bin/bash
#
# Simple example for a script for using Feko with a queuing system
# like Altair PBS Professional.
# To be adapted according to the specific needs.
#
#-------------------------------------------------------------
# Some useful QSUB commands (remove if not required)
# Limit the maximum number of nodes
#QSUB-l mpp_p=8
# Time limit per node in seconds
#QSUB-l p_mpp_t=60
# Time limit for the total request in seconds
#QSUB-l mpp_t=60
# Name of the request
#QSUB-r xxxxx.rqs
# For accounting purposes, use a special account
#QSUB-A yyyyy
# Merge stderr and stdout
#QSUB-eo
# Direct the job log to a file
#QSUB-j xxxxx.log
# Direct stdout to a file
#QSUB-o xxxxx.sto
# Write stdout file while request is executed (allows monitoring)
#QSUB-ro
#-------------------------------------------------------------
# General settings for the Feko job
# Number of parallel processes to be used
nprocs=8
# File with the nodenames to be used
machfile=$PBS_NODEFILE
# Name of the Feko file (without extension)
fekname=xxxxx
# Name of the working directory
workdir=/scratch
#-------------------------------------------------------------
# Avoid immediate job abort when signal 26 (CPU time limit exceeded)
# is received (this gives Altair Feko time to clean up everything)
trap "" 26
echo "==================================================================="
echo "Feko running with file " $fekname " on " $nprocs " processes"
echo "==================================================================="
date
# Go to the correct working directory (where we expect the input file)
cd $workdir
# Start job accounting (if installed)
ja
# Start the parallel Feko job
/opt/feko/bin/runfeko $fekname -np $nprocs --machines-file $machfile
# Accounting output
ja -chl # detailed output
ja -s # summary
ja -t # terminate job accounting
echo "---"
echo "Feko run finished"
date
# The end
exit 0
Script 3
#!/bin/bash
#
# Simple example for a script for using Feko with a queuing system
# like PBS.
# To be adapted according to the specific needs.
#
#-------------------------------------------------------------
# General settings for the Feko job
# Number of parallel processes to be used
nprocs=8
# Name of the Feko file (without extension)
fekname=xxxxx
# Name of the working directory
workdir=/scratch
#-------------------------------------------------------------
echo "==================================================================="
echo "Feko running with file " $fekname " on " $nprocs " processes"
echo "==================================================================="
# Go to the correct working directory (where we expect the input file)
cd $workdir
# Start the parallel Feko job
/opt/feko/bin/runfeko $fekname -np $nprocs --machines-file $PBS_NODEFILE
echo "---"
echo "Feko run finished"
# The end
exit 0