Commit fd201010 authored by Jose A. Lopes's avatar Jose A. Lopes

Add Xen paused state as a Ganeti running state

The QA test 'TestClusterBurnin' pauses instances and the Xen state
domain 'paused' was not being handled properly by Ganeti because it
was not being classified as either a running or shutdown state.  This
patch adds the 'paused' state to the set of running states by
extending the function 'ganeti.hypervisor.hv_xen._IsInstanceRunning'
with the corresponding Xen state string '--p---'.

This fixes the QA test 'TestClusterBurnin'.
Signed-off-by: default avatarJose A. Lopes <jabolopes@google.com>
Reviewed-by: default avatarHelga Velroyen <helgav@google.com>
parent 4757ccc4
......@@ -168,9 +168,14 @@ def _GetAllInstanceList(fn, include_node, _timeout=5):
return _ParseInstanceList(lines, include_node)
# Determine whether an instance is running
#
# An instance is running if it is in the following Xen states:
# running, blocked, or paused.
def _IsInstanceRunning(instance_info):
return instance_info == "r-----" \
or instance_info == "-b----"
or instance_info == "-b----" \
or instance_info == "--p---"
def _IsInstanceShutdown(instance_info):
......
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