DK101010 commented on a change in pull request #4630:
URL: https://github.com/apache/cloudstack/pull/4630#discussion_r620199452
##########
File path:
plugins/hypervisors/vmware/src/main/java/com/cloud/hypervisor/vmware/resource/VmwareResource.java
##########
@@ -1959,15 +1959,18 @@ protected StartAnswer execute(StartCommand cmd) {
}
// Check for hotadd settings
-
vmConfigSpec.setMemoryHotAddEnabled(vmMo.isMemoryHotAddSupported(guestOsId));
-
+
vmConfigSpec.setMemoryHotAddEnabled(vmMo.isMemoryHotAddSupported(guestOsId) &&
vmSpec.isEnableDynamicallyScaleVm());
String hostApiVersion = ((HostMO)
hyperHost).getHostAboutInfo().getApiVersion();
if (numCoresPerSocket > 1 && hostApiVersion.compareTo("5.0") < 0) {
s_logger.warn("Dynamic scaling of CPU is not supported for
Virtual Machines with multi-core vCPUs in case of ESXi hosts 4.1 and prior.
Hence CpuHotAdd will not be"
+ " enabled for Virtual Machine: " + vmInternalCSName);
vmConfigSpec.setCpuHotAddEnabled(false);
} else {
-
vmConfigSpec.setCpuHotAddEnabled(vmMo.isCpuHotAddSupported(guestOsId));
+
vmConfigSpec.setCpuHotAddEnabled(vmMo.isCpuHotAddSupported(guestOsId) &&
vmSpec.isEnableDynamicallyScaleVm());
+ }
+
+ if(!vmMo.isMemoryHotAddSupported(guestOsId) &&
vmSpec.isEnableDynamicallyScaleVm()){
+ s_logger.warn("hotadd is not supported, dynamic scaling
feature can not be applied " + vmInternalCSName);
Review comment:
@harikrishna-patnala no problem, I will adapt it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]