autoupdate.setURL("http://localhost:55555")
self.agent.restartAgent()
xenrt.sleep(60)
- os = self.agent.os
- try:
- os.execCmd("net stop \"XenSvc\" ")
- except:
+ if self.agent.isAgentAlive() == False:
raise xenrt.XRTFailure("Agent Stopped")
\ No newline at end of file
assert isinstance(x, AutoUpdate)
return x
+ def isAgentAlive(self):
+ info = self.os.execCmd("sc query \"XenSvc\" | find \"RUNNING\"")
+ if "RUNNING" in info:
+ return True
+ else:
+ return False
class LicensedFeature(object):
__metaclass__ = ABCMeta
def checkKeyPresent(self):
host = self.guest.host
+ xenrt.TEC().logverbose("----xenstore-exists: %s"%host.xenstoreExists("/guest_agent_features/Guest_agent_auto_update/parameters/enabled"))
+ xenrt.TEC().logverbose("%s" % host.execdom0("xenstore-ls -f"))
return host.xenstoreExists("/guest_agent_features/Guest_agent_auto_update/parameters/enabled")
class VMUser(ActorImp):