#---------------Icebox g03job sample script -------- # #PBS -S /bin/csh #PBS -l walltime=120:00:00,nodes=2:ppn=2 #PBS -N gICE_laa #PBS -e gICE_laa.stderr #PBS -o gICE_laa.stdout # # Other node specifications such as memory can also be added to above, as well # as qos specifications. # # Put in proper WORKDIR, FILENAME in the first two lines below, respectively # Set SCRFLAG to either PARALLEL or SERIAL or TMP (scrubbed automatically at end of job) in third # Put in USER ID for use in scratch directory path # # Also make sure %nprocs and/or %nprocl and %mem are set properly in the com file. # Only works on 1 node (and all nodes are dual so you always need only %nprocs=2) # Allow at least 64MB of the memory available per node for the OS # # Remember that ICEBOX, being a 32bit system, has the limitations of 16GB for max scratch, # rwf, and for memory; there is no longer a need to break these into < 2GB chunks # setenv WORKDIR $HOME/Icebox/ setenv FILENAME laa setenv SCRFLAG SERIAL # # # nothing should need changed below here to run unless you do not # want to use the default version of Gaussian; in this case the # g03root path will need to be changed # cd $WORKDIR setenv g03root /uufs/$CLUSTER/sys/g03 cat $PBS_NODEFILE | uniq > $WORKDIR/Gau.hosts set NODELIST = `xargs echo < Gau.hosts` cat Gau.hosts | xargs >tsnet.nodes echo $NODELIST if ("$SCRFLAG" == "PARALLEL") then setenv GAUSS_SCRDIR /scratch/global/$USER/$PBS_JOBID source $g03root/g03/bsd/g03.login mkdir -p /scratch/global/$USER/$PBS_JOBID cd /scratch/global/$USER/$PBS_JOBID cp $WORKDIR/$FILENAME.com . cp $WORKDIR/$FILENAME.chk . endif if ("$SCRFLAG" == "SERIAL") then setenv GAUSS_SCRDIR /scratch/serial/$USER/$PBS_JOBID source $g03root/g03/bsd/g03.login mkdir -p /scratch/serial/$USER/$PBS_JOBID cd /scratch/serial/$USER/$PBS_JOBID cp $WORKDIR/$FILENAME.com . cp $WORKDIR/$FILENAME.chk . endif if ("$SCRFLAG" == "TMP") then setenv GAUSS_SCRDIR /tmp/$USER/$PBS_JOBID source $g03root/g03/bsd/g03.login mkdir -p /tmp/$USER/$PBS_JOBID endif echo $GAUSS_SCRDIR setenv GAUSS_LFLAGS "-nodelist '$NODELIST'" echo $GAUSS_LFLAGS # Run the program clearipc g03 $FILENAME.com # Clean up scratch space cat $FILENAME.log >> $FILENAME.com mv $FILENAME.com $FILENAME.log if ("$SCRFLAG" == "PARALLEL") then cp *.log $WORKDIR/. cp *.chk $WORKDIR/. cp Test.FChk $WORKDIR/$FILENAME.FChk cd .. rm -r /scratch/global/$USER/$PBS_JOBID endif if ("$SCRFLAG" == "SERIAL") then cp *.log $WORKDIR/. cp *.chk $WORKDIR/. cp Test.FChk $WORKDIR/$FILENAME.FChk cd .. rm -r /scratch/serial/$USER/$PBS_JOBID endif #----- End of g03job ---------