diff --git a/python/elasticbu.py b/python/elasticbu.py index 305ebdb..a8d2d4f 100755 --- a/python/elasticbu.py +++ b/python/elasticbu.py @@ -257,7 +257,7 @@ def elasticize_box(self,infile): #only here document['host']=basename try: - document['detectedStaleHandle']=bool(document['detectedStaleHandle']) + document['detectedStaleHandle']=bool(document['detectedStaleHandle']=='True') except: pass self.index_documents('boxinfo',[document]) diff --git a/python/hltd.py b/python/hltd.py index f341b32..8a87e29 100755 --- a/python/hltd.py +++ b/python/hltd.py @@ -545,7 +545,7 @@ def run(self): mpstat = os.stat(disk) #no issue if we reached this point fu_stale_counter = 0 - except IOError as ex: + except (IOError,OSError) as ex: #TODO:which kind of error is thrown with unresponsive Force10 network if ex.errno == 116: if fu_stale_counter==0 or fu_stale_counter%20==0: @@ -587,10 +587,10 @@ def run(self): numQueuedLumis,maxCMSSWLumi=self.getLumiQueueStat() fp.write('activeRunNumQueuedLS='+numQueuedLumis+'\n') fp.write('activeRunCMSSWMaxLS='+maxCMSSWLumi+'\n') - fp.write('detectedStaleHandle='+str(fu_stale_counter>0)) + fp.write('detectedStaleHandle='+str(fu_stale_counter>0)+'\n') fp.write('entriesComplete=True') boxinfo_update_attempts=0 - except IOError as ex: + except (IOError,OSError) as ex: logger.warning('boxinfo file write failed :'+str(ex)) #detecting stale file handle on recreated loop fs and remount if conf.instance!='main' and (ex.errno==116 or ex.errno==2) and boxinfo_update_attempts>=5: @@ -602,7 +602,7 @@ def run(self): time.sleep(1) boxinfo_update_attempts+=1 except Exception as ex: - logger.warning('boxinfo file write failed +'+str(ex)) + logger.warning('exception on boxinfo file write failed : +'+str(ex)) if conf.role == 'bu': #ramdisk = os.statvfs(conf.watch_directory) diff --git a/scripts/hltdrpm.sh b/scripts/hltdrpm.sh index 1da5893..8aabf40 100755 --- a/scripts/hltdrpm.sh +++ b/scripts/hltdrpm.sh @@ -196,7 +196,7 @@ cd $TOPDIR cat > hltd.spec < fffmeta.spec <