CLOUDSTACK-7919: If there is an out of band movement for the VR, irrespective of the fact that came as out of band live migrate or HA, reboot the router to make sure the router has all the rules configured.

This commit is contained in:
Nitin Mehta 2014-11-14 14:30:37 -08:00
parent 2d4e87973d
commit 39a671dfd8

View File

@ -2577,7 +2577,7 @@ Configurable, StateListener<State, VirtualMachine.Event, VirtualMachine> {
final State oldState = transition.getCurrentState();
final State newState = transition.getToState();
final VirtualMachine.Event event = transition.getEvent();
if (oldState == State.Stopped && event == VirtualMachine.Event.FollowAgentPowerOnReport && newState == State.Running) {
if (event == VirtualMachine.Event.FollowAgentPowerOnReport && newState == State.Running) {
if (vo.getType() == VirtualMachine.Type.DomainRouter) {
s_logger.info("Schedule a router reboot task as router " + vo.getId() + " is powered-on out-of-band. we need to reboot to refresh network rules");
_executor.schedule(new RebootTask(vo.getId()), 1000, TimeUnit.MICROSECONDS);