[XEND] Merge VFB support for PV and HVM guests.

This patch merges the way VFB are represented inside Xend by making
HVM VNC consoles use the VFB as its configuration object.

It preserves the way options are specified through xm but will create
a new VFB device that is used by image.py to put vnc config into
qemu-dm's command line. The parsing is moved into image.py's
parseDeviceModel() rather than in configVNC().

Through the Xen API, you can create a 'console' of protocol 'rfb' and
end up with a VNC console, on both HVM and PV guests. The location of
the connecting port is stored in the location attribute of the console
object. This is updated on each XendDomainInfo.update() if it
changes.

Also fixes missing read of the vnclisten and HVM_boot from the
config when initialised via xm. Makes sure bootable attribute for VBD
is store as an int when making SXP config.

Signed-off-by: Alastair Tse <atse@xensource.com>
This commit is contained in:
Alastair Tse committed 2007-01-31 13:20:36 +00:00
1 parent 6501ac6994
commit f492dd97fb
9 files changed
+342 -89

No files matched your search

+12 -1
View File
@@ -91,6 +91,11 @@ vif_cfg = {
'network': '',
'MAC': '',
'MTU': 1500,
}
console_cfg = {
'protocol': 'rfb',
'other_config': {'vncunused': 1, 'vncpasswd': 'testing'},
}
import sys
@@ -157,12 +162,18 @@ def test_vm_create():
vif_cfg['VM'] = vm_uuid
vif_uuid = execute(server, 'VIF.create', (session, vif_cfg))
# Create a console
console_cfg['VM'] = vm_uuid
console_uuid = execute(server, 'console.create',
(session, console_cfg))
print console_uuid
# Start the VM
execute(server, 'VM.start', (session, vm_uuid, False))
time.sleep(30)
test_suspend = True
test_suspend = False
if test_suspend:
print 'Suspending VM..'
execute(server, 'VM.suspend', (session, vm_uuid))
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.