submit_rwgt_jobs2.sh
Go to the documentation of this file.
1 #! /bin/bash
2 
3 N=1
4 while [ $N -lt 2 ]; do
5  export INFILES=`ls /minerva/data/users/afilkins/rwgt/me000z200i/$N/g4numi*_121_*.root`
6  export OUTDIR="/minerva/data/users/afilkins/rwgt/me000z200i"
7  export PPFX_DIR="/minerva/app/users/afilkins/Summer-2016/ppfx"
8 
9 # create a file with a list of /pnfs/file/name local_subdir
10 # this will be used with the ifdh cp -f
11  if [ -f "$OUTDIR/rwgt_file_list.txt" ]
12  then
13  rm $OUTDIR/rwgt_file_list.txt
14  fi
15 
16  for f in `ls $INFILES`; do
17  echo $f ./inputs/`basename $f`
18  done > $OUTDIR/rwgt_file_list.txt
19 
20 
21 
22  export LOGFILE=rwgt$N.log
23 
24  jobsub_submit -G minerva -M --OS=SL6 --resource-provides=usage_model=DEDICATED,OPPORTUNISTIC --role=Analysis -e LOGFILE -e PPFX_DIR -f $OUTDIR/rwgt_file_list.txt -dRWGT $OUTDIR file:///minerva/app/users/afilkins/Summer-2016/ppfx/scripts/rwgt_job.sh
25 
26  N=$[$N+1]
27 done
28 
29 
30 
31 N=1
32 while [ $N -lt 2 ];do
33 
34  export INFILES=`ls /minerva/data/users/afilkins/rwgt/me000z-200i/$N/g4numi*151*.root`
35  export OUTDIR="/minerva/data/users/afilkins/rwgt/me000z-200i"
36 
37  if [ -f "$OUTDIR/rwgt_file_list.txt" ]
38  then
39  rm $OUTDIR/rwgt_file_list.txt
40  fi
41 
42  for f in `ls $INFILES`; do
43  echo $f ./inputs/`basename $f`
44  done > $OUTDIR/rwgt_file_list.txt
45 
46  export LOGFILE=rwgt$N.log
47 
48  jobsub_submit -G minerva -M --OS=SL6 --resource-provides=usage_model=DEDICATED,OPPORTUNISTIC --role=Analysis -e LOGFILE -e PPFX_DIR -f $OUTDIR/rwgt_file_list.txt -dRWGT $OUTDIR file:///minerva/app/users/afilkins/Summer-2016/ppfx/scripts/rwgt_job.sh
49 
50  N=$[$N+1]
51 done