grycap / clues

CLUES: an energy management system for HPC Clusters and Cloud infrastructures.
http://www.grycap.upv.es/clues
GNU General Public License v3.0
24 stars 7 forks source link

NameError: global name 'schedulers' is not defined #9

Closed tkald closed 7 years ago

tkald commented 8 years ago

When cluesd fails to power on node, it exits with error:

[NODE];DEBUG;2016-11-01 15:52:47,850;1478008367.850;failed to power on node vml-vm1 (3 fails) Traceback (most recent call last): File "/usr/bin/cluesserver", line 569, in main_loop() File "/usr/bin/cluesserver", line 566, in main_loop CLUES_DAEMON.loop(options.RT_MODE) File "/usr/local/lib/python2.7/dist-packages/clueslib/cluesd.py", line 557, in loop cpyutils.eventloop.get_eventloop().loop() File "build/bdist.linux-x86_64/egg/cpyutils/eventloop.py", line 299, in loop File "build/bdist.linux-x86_64/egg/cpyutils/eventloop.py", line 138, in call File "build/bdist.linux-x86_64/egg/cpyutils/eventloop.py", line 101, in call File "/usr/local/lib/python2.7/dist-packages/clueslib/cluesd.py", line 500, in _schedulers_pipeline if not scheduler.schedule(self._requests_queue, monitoring_info, candidates_on, candidates_off): File "/usr/local/lib/python2.7/dist-packages/clueslib/schedulers.py", line 606, in schedule if node.power_on_operation_failed < schedulers.config_scheduling.RETRIES_POWER_ON: NameError: global name 'schedulers' is not defined cluesd.service: Main process exited, code=exited, status=1/FAILURE

Should line 606 in clueslib/cluesd.py just be if node.power_on_operation_failed < config_scheduling.RETRIES_POWER_ON: ?

dealfonso commented 7 years ago

Hi @tkald

you are right. The correction has been included in the master branch.