This commit is contained in:
Joshua Boniface 2018-06-02 00:50:57 -04:00
parent 1db1c80f0b
commit c7600e9396
1 changed files with 1 additions and 7 deletions

View File

@ -35,14 +35,8 @@ class VMInstance:
try: try:
dom = conn.createXML(xmlconfig, 0) dom = conn.createXML(xmlconfig, 0)
except: except:
dom = None
print('Failed to create domain %s' % self.domuuid) print('Failed to create domain %s' % self.domuuid)
self.zk.set(self.zkey + '/state', 'stop'.encode('ascii'))
if dom == None:
try:
self.zk.set(self.zkey + '/status', 'stop'.encode('ascii'))
except Error as e:
print("Problem %s with zookeeper con %s" % (e, self.zk))
return None return None
if not self.domuuid in self.thishypervisor.domain_list: if not self.domuuid in self.thishypervisor.domain_list: