ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CRAB/python/SchedulerLsf.py
(Generate patch)

Comparing COMP/CRAB/python/SchedulerLsf.py (file contents):
Revision 1.8 by spiga, Sat May 3 17:14:17 2008 UTC vs.
Revision 1.14 by spiga, Wed Jun 11 10:03:07 2008 UTC

# Line 17 | Line 17 | class SchedulerLsf(SchedulerLocal) :
17  
18      def __init__(self):
19          Scheduler.__init__(self,"LSF")
20 <
20 >        
21          return
22  
23      def configure(self, cfg_params):
24          SchedulerLocal.configure(self, cfg_params)
25 +        self.outputDir = cfg_params.get('USER.outputdir' ,common.work_space.resDir())
26          self.environment_unique_identifier = "https://"+common.scheduler.name()+":/${LSB_BATCH_JID}-"+ \
27              string.replace(common._db.queryTask('name'),"_","-")
28  
# Line 56 | Line 57 | class SchedulerLsf(SchedulerLocal) :
57                  if (self.res): sched_param += ' -R '+self.res +' '
58              pass
59  
60 <        sched_param+='-cwd '+common.work_space.resDir() + ' '
60 >        sched_param+='-cwd '+ str(self.outputDir)  + ' '
61          return sched_param
62  
63      def loggingInfo(self, id):
# Line 75 | Line 76 | class SchedulerLsf(SchedulerLocal) :
76          txt += '#\n\n'
77  
78          txt += 'func_exit() { \n'
79 <        txt += '    if [ $PYTHONPATH ]; then \n'
80 <        txt += '        update_fjr\n'
81 <        txt += '    fi\n'
82 <        txt += '    cd $RUNTIME_AREA  \n'  
82 <        txt += '    for file in $filesToCheck ; do\n'
83 <        txt += '        if [ -e $file ]; then\n'
84 <        txt += '            echo "tarring file $file in  $out_files"\n'
85 <        txt += '        else\n'
86 <        txt += '            echo "WARNING: output file $file not found!"\n'
87 <        txt += '        fi\n'
88 <        txt += '    done\n'
89 <        txt += '    echo "JOB_EXIT_STATUS = $job_exit_code"\n'
90 <        txt += '    echo "JobExitCode=$job_exit_code" >> $RUNTIME_AREA/$repo\n'
91 <        txt += '    dumpStatus $RUNTIME_AREA/$repo\n'
92 <        txt += '    cp *.${LSB_BATCH_JID}.stdout CMSSW_${NJob}.stdout \n'
93 <        txt += '    cp *.${LSB_BATCH_JID}.stderr CMSSW_${NJob}.stderr \n'
79 >        txt += self.wsExitFunc_common()
80 >
81 >        txt += '    cp *.${LSB_BATCH_JID}.out CMSSW_${NJob}.stdout \n'
82 >        txt += '    cp *.${LSB_BATCH_JID}.err CMSSW_${NJob}.stderr \n'
83          txt += '    tar zcvf ${out_files}.tgz  ${filesToCheck}\n'
84          txt += '    exit $job_exit_code\n'
85          txt += '}\n'

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines