#!/bin/bash # This is a simple script that cd's into scratch # directory, copies some input files to /scr on compute node, # copy the output file from /scr to user's directory (user or storage) # give the job a name #PBS -N test4 # send email notification #PBS -m abe #PBS -M josephs@bu.edu # request 1 node #PBS -l nodes=1 ## join stderr and stdout and write the to a file #PBS -j oe #PBS -o /fs/user2/josephs/Examples/test4.o # cd into the scratch directory created for this job cd /scr/$PBS_JOBID # print out some diagnostic stuff echo Running on host `hostname` echo echo Directory is `pwd` echo echo Start time is `date` echo # copy the date files to scratch cp /fs/user2/josephs/Examples/data.txt . # run my commands. /fs/user2/josephs/Examples/dostuff2.pl data.txt > test4.out1 # copy the output files someplace permanent cp test4.out1 /fs/user2/josephs/Examples # print out some diagnostic stuff echo Stop time is `date` echo