Upload
chester-horton
View
223
Download
3
Embed Size (px)
Citation preview
www.mimos.my © 2010 MIMOS Berhad. All Rights Reserved.
Nazarudin Wijee Mohd Sidek SallehGrid Computing LabMIMOS Berhad
7 Stages Heating System Amber Job Submission in P-GRADE Portal
Background
• User: Universiti Sains Malaysia• Amber Version: 9• Job Type: MPI• No of processor: 32
www.mimos.my © 2010 MIMOS Berhad. All Rights Reserved.
Amber 7 Stages Heating System Workflow
www.mimos.my © 2010 MIMOS Berhad. All Rights Reserved.
#PBS -N Amber #PBS -l select=4:ncpus=8
STAGE=1PROJECT_DIR=job_execution_directoryEXE=/share/apps/amber9/exe/sanderGBIN=$PROJECT_DIR/gbin$STAGEPRMTOP=$PROJECT_DIR/prmtop$STAGEINPCRD=$PROJECT_DIR/inpcrd$STAGERESTRT=$PROJECT_DIR/restrt$STAGETRAJECTORY=$PROJECT_DIR/trajectory$STAGEMDINF=$PROJECT_DIR/mdinfo$STAGEMDOUT=$PROJECT_DIR/mdout$STAGEMDEN=$PROJECT_DIR/mden$STAGEMDVEL=$PROJECT_DIR/mdvel$STAGE
cd $PBS_O_WORKDIR
mpirun -np 32 -machinefile $PBS_NODEFILE $EXE -O -i $GBIN -p $PRMTOP -c $INPCRD -r $RESTRT -x $TRAJECTORY -inf $MDINF -o $MDOUT -e $MDEN -v $MDVEL
• RESTRT file from Stage1 Heating will be used as INPCRD for Stage2 Heating
Amber 7 Stages Heating System Workflow
www.mimos.my © 2010 MIMOS Berhad. All Rights Reserved.
STAGE=1
. /etc/pbs.conf
. executor.infoecho "PBS_SERVER = $PBS_SERVER"echo "PBS_JOBID = $PBS_JOBID"echo "EXEC_NODE = `hostname`"echo "MONITOR_JOB_DIR = `pwd`"echo
# begin monitoringFINISH_STATUS="0"until [[ $FINISH_STATUS -eq "1" ]]do WC=`ssh $PBS_SERVER "tracejob -n 30 $PBS_JOBID | grep 'dequeuing from' | wc -l"` if [[ $WC -eq 1 ]]; then FINISH_STATUS="1" else FINISH_STATUS="0" fidone
echo $WC > tracejob.out
echo "Job $PBS_JOBID has finished..."
RESTRT=$PROJECT_DIR/restrt$STAGETRAJECTORY=$PROJECT_DIR/trajectory$STAGEMDINF=$PROJECT_DIR/mdinfo$STAGEMDOUT=$PROJECT_DIR/mdout$STAGEMDEN=$PROJECT_DIR/mden$STAGEMDVEL=$PROJECT_DIR/mdvel$STAGE
# in case some files were not produced...touch restrt$STAGEtouch trajectory$STAGEtouch mdinfo$STAGEtouch mdout$STAGEtouch mden$STAGEtouch mdvel$STAGE
cp $RESTRT .cp $TRAJECTORY .cp $MDINF .cp $MDOUT .cp $MDEN .cp $MDVEL .
exit 0
What will Monitor job do?1. It will receive PBS Job ID from Submit job2. During runtime, it will goes to cluster head
node and do PBS Pro tracejob to check it the given PBS Job ID already finished.
THANK YOU
www.mimos.my © 2010 MIMOS Berhad. All Rights Reserved.