ESXi 4.1 and multiple vCPUs

farscapesg1

2[H]4U
2FA
Joined
Aug 4, 2004
Messages
2,658
OK, I'm not sure what exactly is going on here...

I built an ESXi 4.1 "white box" with the following components;

MB - Supermicro X8ST3-F
CPU - Intel Xeon e5640 (w/ Hyperthreading enabled)
Memory - 12 GB Kingston ECC DDR3

When I create a VM, even though I designate more than 2 vCPU to the VM, Task Manager only shows 2. Looking at Device Manager I see 4 CPU's for example, but everything else reports back as 2 (Task Manager, Perfmon, etc.).

Am I missing something here? I've tried this with Server 2003, WinXP, and Windows 7 with the same results. The only OS that will show more than 2 CPU is Server 2008 R2.
 
Don't really have the answer to your question, but I am curious as to why are you using more than one vCPU?
 
Video encoding/transcoding/comskip/etc. I use SageTV (PVR software) to record and watch TV and I'm working on moving the server side to a virtual environment. I can probably leave the VM with 2 vCPU (limited testing shows the performance to be just slightly slower than my current AMD 9750 setup). I use Handbrake (running in the early morning hours when no one is trying to watch TV) to encode older recordings to h.264 format, which could use additional cores if made available.

For all my other VMs, 1 vCPU works fine. I just need additional for this one purpose ;)
 
OK first things first. ESXi (without advanced options set) presents vCPUs as fully separate CPUs. So even though you might have a single quad core, meaning 1 socket, 4 cores, the Guest OS will see 4 vCPUs as four separate sockets.

Windows XP, Windows Vista, and 7 are home operating systems typically, but the "professional" or business versions support 2 'sockets'. The home versions support more than one logical processor, but not more than one socket. That is an important distinction to understand how Windows Operating systems treat sockets, cores, and hyper-threading.

Windows 2003 -- that one is throwing me for a loop, but the 'web' version only supports 2 way SMP, any chance its Web rather than at least standard?

You can set advanced options on the VM to set the "cores per socket", so if you change that to "2" for the limited VMs, you would get a single socket presented with 4 cores. I had to edit that previous sentence, because the setting is 2 to the power of x where x must be a multiple of 2. Yeah it is confusing, but Jason Boche wrote a good article on it: http://www.boche.net/blog/index.php/2010/07/25/vsphere-4-1-multicore-virtual-cpus/. Most Operating Systems should display 4 "cores" correctly.
 
Last edited:
OK, thanks. I feel stupid, but I think I understand now. Since the VMs see each vCPU as a socket instead of just as a core, that makes sense why Windows XP Pro only sees 2, as well as WHS (based off of Server 2003, but limited to two sockets).

Now I just have to decide if I want to load SageTV/Handbrake/etc. on Server 2008 so I can make use of the additional cores....

Thanks for setting me straight :)
 
With ESX 4.1 you can actually go in to an advanced setting and have it pass vCPUs as cores to the guest. This is useful for licensing issues, like this. But..you need to be real careful in adding vCPUs. You'll put yourself in a bad spot real fast, especially with a single socket quad-core system.
 
AH the 2003 Server was WHS. HAHA, I was like what the hell, who uses web? It has its purpose, but I was waiting for your reply with anticipation.

NetJunkie and I both let you know you can still do what you want, with little effort. See the link above in my original post to Jason Boche's article on how to pass the cores through. This will get you what you want. NetJunkie's warning is important too, don't overcommit your physical core count *too* much. You can do a lot of reading about vSMP and what to watch for, most importantly the CPU Ready metric to see if you've gone too far. I won't get into detail, but use your google-fu. Mainly, it is hard to give solid one-size-fits-all advice because it depends on your guest os's workloads, etc, every environment is different.
 
NetJunkie and I both let you know you can still do what you want, with little effort. See the link above in my original post to Jason Boche's article on how to pass the cores through. This will get you what you want. NetJunkie's warning is important too, don't overcommit your physical core count *too* much. You can do a lot of reading about vSMP and what to watch for, most importantly the CPU Ready metric to see if you've gone too far. I won't get into detail, but use your google-fu. Mainly, it is hard to give solid one-size-fits-all advice because it depends on your guest os's workloads, etc, every environment is different.

Sorry..I skimmed your post and didn't see the link to Boche's post.
 
oh no big deal man...

You never did respond to my PM though, so I do feel unimportant... I must admit!
 
oh no big deal man...

You never did respond to my PM though, so I do feel unimportant... I must admit!

Thought about that today. It's on my list, I promise. :) New position at work has me scrambling. Updating firmware on the new Cisco UCS gear we got for the lab in my other window right now....
 
Again, thanks for the detailed information (and the link). I'm hesitant to devote all 4 CPUs to the VM though. I was really hoping for 3 actually (to leave one core available for the underlying ESXi tasks as well as additional VMs running). It looks like my best option is to configure them for 2 vCPU and take the slight performance hit compared to the old system (we are only talking about approximately 10 minutes difference for a DVD rip to encode to h.264 format).

I did test it after configuring it per the document so it would see 4 vCPU, and the DVD conversion I've been testing with that takes approximately 55 minutes on the AMD box, took only 18 minutes :D The VCenter VM (Server 2003) was the only other VM running at the same time though, but at least it didn't crash ;)
 
Run all 4 cpu's to the VM, it will be fine. If you are taxing it against the others, you can set limits for its usage, or set the priority for that VM with 4 vcpus to low so that it takes everything no one else is using, but lets everyone else have anything they need.
 
I've thought about it... but I don't trust the version they have out yet with my data :) I'm willing to take some chances and try things that aren't "officially" supported, but after all the issues WHSv1 had when it was first released, I'm hesitant to go to Vail before it has been out a couple months, let alone while it is still in Beta...
 
Back
Top