mirror of https://github.com/apache/cloudstack.git
HA: no need to investigate why vm was stopped on host when host is being Dicsonnected with investigate=false option
This commit is contained in:
parent
8271f034ce
commit
7255d68875
|
|
@ -1588,7 +1588,7 @@ public class AgentManagerImpl implements AgentManager, HandlerFactory, ResourceS
|
|||
|
||||
host = _hostDao.findById(host.getId());
|
||||
if (host.getStatus() == Status.Alert || host.getStatus() == Status.Down) {
|
||||
_haMgr.scheduleRestartForVmsOnHost(host);
|
||||
_haMgr.scheduleRestartForVmsOnHost(host, investigate);
|
||||
}
|
||||
|
||||
for (Pair<Integer, Listener> monitor : _hostMonitors) {
|
||||
|
|
|
|||
|
|
@ -78,8 +78,9 @@ public interface HighAvailabilityManager extends Manager {
|
|||
/**
|
||||
* Schedule restarts for all vms running on the host.
|
||||
* @param host host.
|
||||
* @param investigate TODO
|
||||
*/
|
||||
void scheduleRestartForVmsOnHost(HostVO host);
|
||||
void scheduleRestartForVmsOnHost(HostVO host, boolean investigate);
|
||||
|
||||
/**
|
||||
* Schedule the vm for migration.
|
||||
|
|
|
|||
|
|
@ -179,7 +179,7 @@ public class HighAvailabilityManagerImpl implements HighAvailabilityManager, Clu
|
|||
}
|
||||
|
||||
@Override
|
||||
public void scheduleRestartForVmsOnHost(final HostVO host) {
|
||||
public void scheduleRestartForVmsOnHost(final HostVO host, boolean investigate) {
|
||||
|
||||
if (host.getType() != Host.Type.Routing) {
|
||||
return;
|
||||
|
|
@ -216,9 +216,9 @@ public class HighAvailabilityManagerImpl implements HighAvailabilityManager, Clu
|
|||
|
||||
for (final VMInstanceVO vm : vms) {
|
||||
if (s_logger.isDebugEnabled()) {
|
||||
s_logger.debug("Notifying HA Mgr of to investigate vm " + vm.getId() + "-" + vm.getName());
|
||||
s_logger.debug("Notifying HA Mgr of to restart vm " + vm.getId() + "-" + vm.getName());
|
||||
}
|
||||
scheduleRestart(vm, true);
|
||||
scheduleRestart(vm, investigate);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue