CLOUDSTACK-8491: Host maintenance fails if a vm on it is running a custom service offering VM

This commit is contained in:
Abhinandan Prateek 2015-05-21 10:40:59 +05:30
parent 19f3166a3d
commit 4222364bea
1 changed files with 2 additions and 1 deletions

View File

@ -2358,7 +2358,8 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac
throw new CloudRuntimeException("Unable to find " + vmUuid);
}
final VirtualMachineProfile profile = new VirtualMachineProfileImpl(vm);
ServiceOfferingVO offeringVO = _offeringDao.findById(vm.getId(), vm.getServiceOfferingId());
final VirtualMachineProfile profile = new VirtualMachineProfileImpl(vm, null, offeringVO, null, null);
final Long hostId = vm.getHostId();
if (hostId == null) {