vCPU allocation to a VM on XenServer

 


1
down vote favorite
 
share [g+] share [fb] share [tw]

I recently upgrade a HP server from one used CPU socket (4 cores + HT = 8 cores) to 2 used CPUsockets (16 cores).

However, I'm only able to assign 8 cores to a VM. When setting 16 it defaults back to 8 in the "new VM wizard", and when changing it from an existing VM it displays a red warning: "More VCPUs than physical CPUs may lead to reducded VM performance". Clicking ok still defaults it to 8 cores instead of 16.

enter image description here

My xenhost (dom0) however does have 16 CPUs allocated and actually recognises them.

enter image description here

I'm wondering why I am unable to add more than 8 vCPUs to a machine.

Prior to doing the server upgrade I was able to allocate 8 vCPUs as well, so it can't be HT related.

 

 

1 Answer

 

XenServer supports more than 8 virtual CPUs in a guest, but the XenCenter GUI interface imposes a hard limit of 8. If you want to use more than 8 VCPUs for a guest, you must do so via the 'xe' command line:

xe vm-param-set uuid=your_vms_uuid VCPUs-at-startup=16    xe vm-param-set uuid=your_vms_uuid VCPUs-max=16 

To find 'your_vms_uuid', you can use:

xe vm-list name-label=VMname 

Where "VMname" is the human readable name you assigned in XenCenter.

Now, having given you the secret to allocating more than 8, I have to warn that you probably do not want to do thisMore vCPUs does not automatically equal more performance, especially if there aremultiple VMs running on this XenServer instance. Also realize that a HT CPU does not equal a full extra CPU.

About the only scenario I can think of in which you'd want to hand all of your physical CPUs over to a single guest would be if you're doing 1:1 virtualization of an application that has been proven capable of scaling well to the number of CPUs you're trying to use. Otherwise you're just causing additional CPU scheduling overhead in the hypervisor.

 

 

你可能感兴趣的:(xenserver,vcpu)