bug 10628: root cause is CheckHealthCommand return false, XenServerInvestigator is not called

status 10628: resolved fixed
This commit is contained in:
anthony 2011-07-14 20:42:26 -07:00
parent f15fae8983
commit 0c53bddb16
2 changed files with 2 additions and 15 deletions

View File

@ -854,8 +854,8 @@ public class AgentManagerImpl implements AgentManager, HandlerFactory, Manager {
Request req = new Request(hostId, _nodeId, new CheckHealthCommand(), true);
req.setSequence(agent.getNextSequence());
Answer[] answers = agent.send(req, 50 * 1000);
if (answers != null && answers[0] != null) {
Status status = answers[0].getResult() ? Status.Up : Status.Down;
if (answers != null && answers[0] != null && answers[0].getResult()) {
Status status = Status.Up;
if (s_logger.isDebugEnabled()) {
s_logger.debug("agent (" + hostId + ") responded to checkHeathCommand, reporting that agent is " + status);
}

View File

@ -185,19 +185,6 @@ public class HighAvailabilityManagerImpl implements HighAvailabilityManager, Clu
if (host.getType() != Host.Type.Routing) {
return;
}
// need to wait 60 seconds to make sure storage heartbeat check correct
long begin = System.currentTimeMillis();
while ( true ) {
try {
Thread.sleep(60*1000);
} catch (InterruptedException e) {
}
long now = System.currentTimeMillis();
if( (now - begin) > 60*1000) {
break;
}
}
s_logger.warn("Scheduling restart for VMs on host " + host.getId());
final List<VMInstanceVO> vms = _instanceDao.listByHostId(host.getId());