VMware Cloud Community
spikfrank
Enthusiast
Enthusiast

1 virtual cpu = 1 physical core?

I'm using VMware ESXi 3.5 Update 5. I'm a little confused on what exactly a virtual cpu is.

Does a virtual CPU use an entire physical processor? Or is it on a per core basis?

Reply
0 Kudos
9 Replies
DSTAVERT
Immortal
Immortal

A vCPU is based on cores. I would always start with a single vCPU and add any additional only if necessary.

-- David -- VMware Communities Moderator
Reply
0 Kudos
idle-jam
Immortal
Immortal

1 core = 1 virtual CPU. A VM will be reassigned to another core every 20ms.

Reply
0 Kudos
ThompsG
Virtuoso
Virtuoso

Hi,

Does a virtual CPU use an entire physical processor?


An entire physical processor/core is NOT dedicated to a vCPU but is shared with other virtual machines/vCPUs. As mentioned by idle-jam, ESX will look to move the workload to another core every 20ms (by default) if required. While your vCPU is running on a core it can consume the whole core but this is time sliced with other vCPUs.

Hope this has helped rather than confused.

Kind regards.

Reply
0 Kudos
zipher
Contributor
Contributor

It is my experience, that using more vcores is a good idea if you are installing any newer OS. Atleast with 2008(R2) server, it means alot to have atleast 2 vcpu's. The performance is going up alot, but more than that i think you need to have a very specific requirement. It will most likely give a bigger overhead to the system if you overdo it.

regards Johan Cardel
Reply
0 Kudos
SAKI201110141
Contributor
Contributor

Hi,

I have a question related to this discussion. 

Can I assign multple CPU cores (virtual CPUs) to a single VM having Fault Tolrance enabled?

Regards.

SAKI

Reply
0 Kudos
idle-jam
Immortal
Immortal

Hi Saki,

Welcome to the community.

It would be nicer to create a new thread rather than to hijack with some other question. Anyway to answer you, FT only supports 1vCPU virtual machine only.

Reply
0 Kudos
AWo
Immortal
Immortal

But we can make it a little bit more complex...

If Hyperthreading is enabled, a single core is presented to the OS/Hypervisor (ESX) as two logical processors. But ESX knows about that. The guest doesn't. If tasks from the guests needed to be scheduled by ESX it can decide if it schedules the task directly to a physical core or to a logical processor (generated by Hyperthreading). ESX chooses the latter if no core is free to schedule work to. It then schedules the work to a logical processor and is free to grap the next task. The real scheduling is then up to the processor and not to ESX anymore which gives you a slight performance benefit if more vCPU's are assigned to guests than physical cores exists in combination with a certain amount of load, especially if guests use SMP (more than one vCPU).

AWo

vExpert 2009/10/11 [:o]===[o:] [: ]o=o[ :] = Save forests! rent firewood! =
Reply
0 Kudos
SAKI201110141
Contributor
Contributor

Hi AWO,

Thanks for your support. Can we enable Hyper-threading for FT in VMWare, as I have disabled it currently and unable to add multiple vCPUs in my VM? After your comment, Should I conclude that I need ot enable Hyper-threading first, and then I can use multiple processor cores (multiple vCPUs) in VM for FT.

Regards.

SAKI

Reply
0 Kudos
AWo
Immortal
Immortal

FT supports only one vCPU.

HT should be O.K. as the guest is not aware of HT.

Check

http://pubs.vmware.com/vsphere-esxi-4-1-installable/wwhelp/wwhimpl/js/html/wwhelp.htm#href=availabil...

http://pubs.vmware.com/vsphere-esxi-4-1-installable/wwhelp/wwhimpl/js/html/wwhelp.htm#href=availabil...

AWo

vExpert 2009/10/11 [:o]===[o:] [: ]o=o[ :] = Save forests! rent firewood! =
Reply
0 Kudos