Skip to content

Commit

Permalink
GT fixed and cmsStage, cmsLs, ... scripts replaced by xrdcp, eos ls ...
Browse files Browse the repository at this point in the history
  • Loading branch information
cschomak committed Dec 15, 2015
1 parent 06fef27 commit 5c1998e
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 16 deletions.
5 changes: 3 additions & 2 deletions Alignment/APEEstimation/test/SkimProducer/cmsRemove.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/sh

eos="/afs/cern.ch/project/eos/installation/cms/bin/eos.select"

#directory="/store/caf/user/hauk/data/mu/Run2010B_Dec22ReReco/"
directory="/store/caf/user/ajkumar/ApeSkim/zmumu50/"
Expand Down Expand Up @@ -39,10 +40,10 @@ while [ $counter -le 1000 ]
do
fullname="${filebase}${counter}${filesuffix}"

cmsLs ${fullname}
$eos ls ${fullname}
if [ $? -eq 0 ] ; then
echo "Delete file: ${counter}";
cmsRm ${fullname}
$eos rm ${fullname}
else
echo "Last file reached: ${counter}"; exit 0;
fi
Expand Down
20 changes: 11 additions & 9 deletions Alignment/APEEstimation/test/SkimProducer/cmsRename.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/sh

eos="/afs/cern.ch/project/eos/installation/cms/bin/eos.select"

if [ ! $# == 1 ]; then
echo "Usage: $0 sample"
exit 1
Expand Down Expand Up @@ -36,12 +38,12 @@ declare -i counter=1
inputFilename="${filebase}${filesuffix}"
outputFilename="${filebase}${counter}${filesuffix}"

cmsStageIn $inputFilename $tempFile
xrdcp root://eoscms//eos/cms${inputFilename} $tempFile

if [ ! -f $tempFile ] ; then echo "Last file reached: 0"; exit 0; fi
cmsStageOut $tempFile $outputFilename
xrdcp $tempFile root://eoscms//eos/cms${outputFilename}
if [ $? -eq 0 ] ; then
cmsRm ${filebase}${filesuffix}
$eos rm ${filebase}${filesuffix}
fi
rm $tempFile

Expand All @@ -53,11 +55,11 @@ do
inputFilename="${filebase}00${counter}${filesuffix}"
outputFilename="${filebase}${counterIncrement}${filesuffix}"

cmsStageIn $inputFilename $tempFile
xrdcp root://eoscms//eos/cms${inputFilename} $tempFile
if [ ! -f $tempFile ] ; then echo "Last file reached: ${counter}"; exit 0; fi
cmsStageOut $tempFile $outputFilename
xrdcp $tempFile root://eoscms//eos/cms${outputFilename}
if [ $? -eq 0 ] ; then
cmsRm $inputFilename
$eos rm $inputFilename
fi
rm $tempFile

Expand All @@ -75,11 +77,11 @@ do
inputFilename="${filebase}0${counterTen}${filesuffix}"
outputFilename="${filebase}${counterTenIncrement}${filesuffix}"

cmsStageIn $inputFilename $tempFile
xrdcp root://eoscms//eos/cms${inputFilename} $tempFile
if [ ! -f $tempFile ] ; then echo "Last file reached: ${counterTen}"; exit 0; fi
cmsStageOut $tempFile $outputFilename
xrdcp $tempFile root://eoscms//eos/cms${outputFilename}
if [ $? -eq 0 ] ; then
cmsRm $inputFilename
$eos rm $inputFilename
fi
rm $tempFile

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@

process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_condDBv2_cff')
from Configuration.AlCa.GlobalTag_condDBv2 import GlobalTag
process.GlobalTag = GlobalTag(process.GlobalTag, 'GR_P_V56', '')
process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:run2_data', '')
print "Using global tag "+process.GlobalTag.globaltag._value

process.load("Configuration.StandardSequences.Services_cff")
Expand Down
2 changes: 1 addition & 1 deletion Alignment/APEEstimation/test/batch/cp.bash
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ ls -l

for file in *.root;
do
cmsStageOut $file ${directory}${file}
xrdcp $file root://eoscms//eos/cms${directory}${file}
done


Expand Down
2 changes: 1 addition & 1 deletion Alignment/APEEstimation/test/batch/skimProducer.bash
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ ls -l

for file in *.root;
do
cmsStageOut $file ${directory}${file}
xrdcp $file root://eoscms//eos/cms${directory}${file}
done


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ source /afs/cern.ch/cms/caf/setup.csh
cd -


cmsStageIn _THE_INPUTBASE__THE_NUMBER_.root reco.root
xrdcp _THE_INPUTBASE__THE_NUMBER_.root reco.root


cmsRun $CMSSW_BASE/src/Alignment/APEEstimation/test/cfgTemplate/apeEstimator_cfg.py_THE_COMMANDS_
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ BATCH_OUTPUTBASE1="${CMSSW_BASE}/src/Alignment/APEEstimation/test/batch/workingA
BATCH_OUTPUTSUFFIX=".tcsh"

helpFile1="help1.txt"
cat $BATCH_TEMPLATEFILE |sed "s/_THE_INPUTBASE_/${inputBase}/g" > $helpFile1
cat $BATCH_TEMPLATEFILE |sed "s/_THE_INPUTBASE_/root:\/\/eoscms\/\/eos\/cms\/${inputBase}/g" > $helpFile1



Expand Down

0 comments on commit 5c1998e

Please sign in to comment.