[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] Fix xm block-list through the Xen-API for managed domains.
# HG changeset patch # User Ewan Mellor <ewan@xxxxxxxxxxxxx> # Date 1174412015 0 # Node ID 07d1bd92ade8cde4ed6862d76f8a60309b539ec8 # Parent ee06d8b5712f7fd35f572f3182da160f915d691b Fix xm block-list through the Xen-API for managed domains. Signed-off-by: Tom Wilkie <tom.wilkie@xxxxxxxxx> --- tools/python/xen/xm/main.py | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletion(-) diff -r ee06d8b5712f -r 07d1bd92ade8 tools/python/xen/xm/main.py --- a/tools/python/xen/xm/main.py Tue Mar 20 17:30:52 2007 +0000 +++ b/tools/python/xen/xm/main.py Tue Mar 20 17:33:35 2007 +0000 @@ -37,6 +37,7 @@ import datetime import datetime from select import select import xml.dom.minidom +from xen.util.blkif import blkdev_name_to_number import warnings warnings.filterwarnings('ignore', category=FutureWarning) @@ -1724,7 +1725,12 @@ def xm_block_list(args): vbd_refs = server.xenapi.VM.get_VBDs(get_single_vm(dom)) vbd_properties = \ map(server.xenapi.VBD.get_runtime_properties, vbd_refs) - devs = map(lambda x: [x.get('virtual-device'), map2sxp(x)], vbd_properties) + vbd_devs = \ + map(server.xenapi.VBD.get_device, vbd_refs) + vbd_devids = \ + map(blkdev_name_to_number, vbd_devs) + devs = map(lambda (devid, prop): [devid, map2sxp(prop)], + zip(vbd_devids, vbd_properties)) else: devs = server.xend.domain.getDeviceSxprs(dom, 'vbd') _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |