1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

vCenter capacity presented to VMs based on VCPU and CPU

This commit is contained in:
Tino Vazquez 2015-06-10 15:08:12 +02:00
parent b7a862bed0
commit dd12b9f041

View File

@ -738,7 +738,7 @@ class VCenterVm
# Find out if we need to reconfigure capacity
xml = REXML::Document.new xml_text
expected_cpu = xml.root.elements["//TEMPLATE/CPU"].text
expected_cpu = xml.root.elements["//TEMPLATE/VCPU"].text
expected_memory = xml.root.elements["//TEMPLATE/MEMORY"].text
current_cpu = vm.config.hardware.numCPU
current_memory = vm.config.hardware.memoryMB
@ -1380,7 +1380,7 @@ private
# Capacity section
cpu = xml.root.elements["//TEMPLATE/CPU"].text
cpu = xml.root.elements["//TEMPLATE/VCPU"].text
memory = xml.root.elements["//TEMPLATE/MEMORY"].text
capacity_spec = {:numCPUs => cpu.to_i,
:memoryMB => memory }