Adf08 large.sh: Difference between revisions

From Wiki
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
go back to Main Page, Computational Resources, Clusters, External Resources, Cesca
go back to [Main Page], [Computational Resources], [Clusters], [External Resources], [Cesca]


It maybe a simpler script able to submit the calculations and get the results, but that works.
It maybe a simpler script able to submit the calculations and get the results, but that works.

Revision as of 11:42, 9 November 2010

go back to [Main Page], [Computational Resources], [Clusters], [External Resources], [Cesca]

It maybe a simpler script able to submit the calculations and get the results, but that works.

It creates a submision script nameinput.cmd, and an executable nameinput.lsf, and submits the nameinput.smd to the queue large.

To use it just type:

adf08_large.sh nameinput

the input file should be called nameinput.in

---

#!/usr/local/bin/ksh

echo '#!/bin/ksh' >$1.cmd

echo '#BSUB -J '$1'.in' >>$1.cmd

echo '#BSUB -q large' >>$1.cmd

echo '#BSUB -o '$1'.log' >>$1.cmd

echo '#BSUB -e '$1'.err' >>$1.cmd

echo '#BSUB -B -N -u mbesora@iciq.es' >>$1.cmd

echo '#BSUB -n 1' >>$1.cmd

echo '#BSUB -R "select[adf0801] span[hosts=1]"' >>$1.cmd

echo ' ' >>$1.cmd

echo 'date' >>$1.cmd

echo 'cd '$TMPDIR/mbesora' ' >>$1.cmd

echo 'cp '$PWD'/'$1'.lsf .' >>$1.cmd

echo ' ' >>$1.cmd


echo '#! /bin/sh' >>$1.lsf

echo 'if test -z "$SCM_TESTOUTPUT" ; then SCM_TESTOUTPUT='$1'.out; fi'>>$1.lsf

echo ' ' >>$1.lsf

echo '$ADFBIN/adf << eor >> $SCM_TESTOUTPUT' >>$1.lsf

echo ' ' >>$1.lsf

cat $1.in >>$1.lsf

chmod 755 $1.lsf


echo 'adf2008.01 ./'$1'.lsf>'$1'.out' >>$1.cmd

echo ' ' >>$1.cmd

echo 'cp '$1'.* '$PWD'/' >>$1.cmd

echo 'rm -f TAPE21 *.t21' >>$1.cmd

bsub < $1.cmd