bug 6500: add back the special handle for secodary storage host, it is in the same path of handling xenserver host, it is easy to break that, so I add some comments there

status 6500: resolved fixed
This commit is contained in:
anthony 2010-10-11 11:59:10 -07:00
parent 059077ce9f
commit b0a3f329a0
2 changed files with 4 additions and 7 deletions

View File

@ -3929,12 +3929,7 @@ public abstract class CitrixResourceBase implements StoragePoolResource, ServerR
} finally {
sshConnection.close();
}
try {
// wait 2 seconds before call plugin
Thread.sleep(2000);
} catch (final InterruptedException ex) {
}
if (!setIptables()) {
s_logger.warn("set xenserver Iptable failed");
}

View File

@ -910,10 +910,12 @@ public class AgentManagerImpl implements AgentManager, HandlerFactory {
Long dcId = host.getDataCenterId();
ReadyCommand ready = new ReadyCommand(dcId);
Answer answer = easySend(hostId, ready);
Answer answer = easySend(hostId, ready);
if (answer == null) {
// this is tricky part for secondary storage
// make it as disconnected, wait for secondary storage VM to be up
// return the attache instead of null, even it is disconnectede
handleDisconnect(attache, Event.AgentDisconnected, false);
return null;
}
_hostDao.updateStatus(host, Event.Ready, _nodeId);