CLOUDSTACK-7763 Reservations for VMware VMs remain after dynamic scaling

This commit is contained in:
Bharat Kumar 2014-10-22 11:29:22 +05:30 committed by Kishan Kavala
parent de3eb88b33
commit 0e7f1ea9b8

View File

@ -1281,7 +1281,7 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa
VmwareHypervisorHost hyperHost = getHyperHost(context); VmwareHypervisorHost hyperHost = getHyperHost(context);
VirtualMachineMO vmMo = hyperHost.findVmOnHyperHost(cmd.getVmName()); VirtualMachineMO vmMo = hyperHost.findVmOnHyperHost(cmd.getVmName());
VirtualMachineConfigSpec vmConfigSpec = new VirtualMachineConfigSpec(); VirtualMachineConfigSpec vmConfigSpec = new VirtualMachineConfigSpec();
int ramMb = (int)(vmSpec.getMinRam() / (1024 * 1024)); int ramMb = getReservedMemoryMb(vmSpec);
long hotaddIncrementSizeInMb; long hotaddIncrementSizeInMb;
long hotaddMemoryLimitInMb; long hotaddMemoryLimitInMb;
long requestedMaxMemoryInMb = vmSpec.getMaxRam() / (1024 * 1024); long requestedMaxMemoryInMb = vmSpec.getMaxRam() / (1024 * 1024);