Commit d313785b authored by Alain Takoudjou's avatar Alain Takoudjou

Preven multiple start of condor deamons

parent cb875096
...@@ -177,10 +177,10 @@ class Recipe(GenericBaseRecipe): ...@@ -177,10 +177,10 @@ class Recipe(GenericBaseRecipe):
#elif self.role == "execute": #elif self.role == "execute":
# binary = os.path.join(self.wrapper_bin, 'condor_run') # binary = os.path.join(self.wrapper_bin, 'condor_run')
start_bin = os.path.join(self.wrapper_sbin, 'condor_master') start_bin = os.path.join(self.wrapper_sbin, 'condor_master')
restart_bin = os.path.join(self.wrapper_sbin, 'condor_restart') condor_status = os.path.join(self.wrapper_bin, 'condor_status')
wrapper = self.createPythonScript(start_condor, wrapper = self.createPythonScript(start_condor,
'%s.configure.condorStart' % __name__, '%s.configure.condorStart' % __name__,
dict(start_bin=start_bin, restart_bin=restart_bin) dict(start_bin=start_bin, condor_status=condor_status)
) )
path_list.append(wrapper) path_list.append(wrapper)
return path_list return path_list
......
...@@ -48,7 +48,7 @@ def submitJob(args): ...@@ -48,7 +48,7 @@ def submitJob(args):
def condorStart(args): def condorStart(args):
"""Start Condor if deamons is currently stopped""" """Start Condor if deamons is currently stopped"""
result = os.system(args['restart_bin']) result = os.system(args['condor_status'])
if result != 0: if result != 0:
#process failled to restart that mean that condor deamons is not curently started #process failled to restart that mean that condor deamons is not curently started
os.system(args['start_bin']) os.system(args['start_bin'])
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment