In the XenAPI simulator, set VM.domid, when creating the instance initially,
and when starting the VM. This shows up in the logs for Bug #831599, but this fix doesn't actually fix the hang.
This commit is contained in:
@@ -18,6 +18,8 @@
|
|||||||
|
|
||||||
import eventlet
|
import eventlet
|
||||||
import json
|
import json
|
||||||
|
import random
|
||||||
|
|
||||||
from nova.virt import xenapi_conn
|
from nova.virt import xenapi_conn
|
||||||
from nova.virt.xenapi import fake
|
from nova.virt.xenapi import fake
|
||||||
from nova.virt.xenapi import volume_utils
|
from nova.virt.xenapi import volume_utils
|
||||||
@@ -191,6 +193,7 @@ class FakeSessionForVMTests(fake.SessionBase):
|
|||||||
vm['power_state'] = 'Running'
|
vm['power_state'] = 'Running'
|
||||||
vm['is_a_template'] = False
|
vm['is_a_template'] = False
|
||||||
vm['is_control_domain'] = False
|
vm['is_control_domain'] = False
|
||||||
|
vm['domid'] = random.randrange(0, 1 << 16)
|
||||||
|
|
||||||
def VM_snapshot(self, session_ref, vm_ref, label):
|
def VM_snapshot(self, session_ref, vm_ref, label):
|
||||||
status = "Running"
|
status = "Running"
|
||||||
@@ -290,6 +293,7 @@ class FakeSessionForMigrationTests(fake.SessionBase):
|
|||||||
vm['power_state'] = 'Running'
|
vm['power_state'] = 'Running'
|
||||||
vm['is_a_template'] = False
|
vm['is_a_template'] = False
|
||||||
vm['is_control_domain'] = False
|
vm['is_control_domain'] = False
|
||||||
|
vm['domid'] = random.randrange(0, 1 << 16)
|
||||||
|
|
||||||
|
|
||||||
def stub_out_migration_methods(stubs):
|
def stub_out_migration_methods(stubs):
|
||||||
|
Reference in New Issue
Block a user