direct-io.hg

changeset 6807:383f1336c305

Move uuid back into main domain dir.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
author cl349@firebug.cl.cam.ac.uk
date Wed Sep 14 13:37:03 2005 +0000 (2005-09-14)
parents cc1572db6a3d
children e2f0a6fdb7d9
files tools/python/xen/xend/XendDomain.py tools/python/xen/xend/XendDomainInfo.py tools/python/xen/xend/image.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomain.py	Wed Sep 14 12:49:13 2005 +0000
     1.2 +++ b/tools/python/xen/xend/XendDomain.py	Wed Sep 14 13:37:03 2005 +0000
     1.3 @@ -142,7 +142,7 @@ class XendDomain:
     1.4                  domdb.delete()
     1.5              elif domid in doms:
     1.6                  try:
     1.7 -                    self._new_domain(db.uuid, db, doms[domid]) 
     1.8 +                    self._new_domain(domdb["uuid"].getData(), db, doms[domid]) 
     1.9                  except Exception, ex:
    1.10                      log.exception("Error recreating domain info: id=%d", domid)
    1.11                      self._delete_domain(domid)
     2.1 --- a/tools/python/xen/xend/XendDomainInfo.py	Wed Sep 14 12:49:13 2005 +0000
     2.2 +++ b/tools/python/xen/xend/XendDomainInfo.py	Wed Sep 14 13:37:03 2005 +0000
     2.3 @@ -205,7 +205,6 @@ class XendDomainInfo:
     2.4      __exports__ = [
     2.5          DBVar('id',            ty='int'),
     2.6          DBVar('name',          ty='str'),
     2.7 -        DBVar('uuid',          ty='str'),
     2.8          DBVar('config',        ty='sxpr'),
     2.9          DBVar('start_time',    ty='float'),
    2.10          DBVar('state',         ty='str'),
    2.11 @@ -219,6 +218,7 @@ class XendDomainInfo:
    2.12      def __init__(self, uuid, path, db):
    2.13          self.uuid = uuid
    2.14          self.path = path + "/" + uuid
    2.15 +
    2.16          self.db = db
    2.17  
    2.18          self.recreate = 0
    2.19 @@ -264,6 +264,8 @@ class XendDomainInfo:
    2.20          self.bootloader = None
    2.21          self.device_model_pid = 0
    2.22  
    2.23 +        xstransact.Write(self.path, "uuid", self.uuid)
    2.24 +
    2.25      def setDB(self, db):
    2.26          self.db = db
    2.27  
     3.1 --- a/tools/python/xen/xend/image.py	Wed Sep 14 12:49:13 2005 +0000
     3.2 +++ b/tools/python/xen/xend/image.py	Wed Sep 14 13:37:03 2005 +0000
     3.3 @@ -155,7 +155,6 @@ class ImageHandler:
     3.4              if dom <= 0:
     3.5                  raise VmError('Creating domain failed: name=%s' % self.vm.name)
     3.6          log.debug("initDomain: cpu=%d mem_kb=%d ssidref=%d dom=%d", cpu, mem_kb, ssidref, dom)
     3.7 -        # xc.domain_setuuid(dom, uuid)
     3.8          xc.domain_setcpuweight(dom, cpu_weight)
     3.9          xc.domain_setmaxmem(dom, mem_kb)
    3.10