Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What is the difference between die the VCPU setting in the XML config files and the -smp switch for the kvm command line?

We have a i7-920 with 4 Cores and HT (which results in 8 visible/virtual cores) and want to assign each guest one real core and so 2 virtual cores through HT. What is the best way to do this?

share|improve this question
up vote 0 down vote accepted

I believe the VCPU stanza in the libvirt config xml's simply translates to the -smp N argument to kvm while booting. So they should be the same. You'll probably want to give 2 as the value.

You'll want linux to intelligently handle the assignment. In theory you could set the cpu affinity and select a real core and a HT one, but I doubt this will give the best results and will involve extra hurdles.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.