VMware Cloud Community
proden20
Hot Shot
Hot Shot
Jump to solution

Virtual machine CPU performance questions

I am working on a brand new ESX 3.5 install. There are 2 quad core 2GHz Xeons in each host, with 3 hosts total. 96MB of RAM overall. Virtual machines will be created as follows:

30 workstations Windows XP SP2 - 20GB HD/256MB/1 vpu

20 Windows 2003 Servers - 15-20GB OS HD/512MB/1 vpu

3 workstations Windows XP SP2- 20GB HD/1GB/1vpu

The last 3 workstations will be running a graphics-intensive development tool. Running a simulation on one of these VM's takes 3x longer than on a physical machine with a P4 2.8GHz and 2GB RAM. The performance charts show the guest reporting that the CPU is being hit hard, but memory is fine. We upped the VM to 2vpu's and interestingly enough the CPU is not spiking on the charts anymore, although the application is not completeing any faster as it is not multithreaded. Why did the CPU stop spiking on the graph?

Second...my boss insisted that "something is limiting the processor." I told him nothing is limiting the processor because at the moment the host's resources are nowhere near being fully utilized. I added that increasing CPU shares/resource pools won't have an impact on the machine's performance until contention exists. Was I correct?

I am having a difficult time grasping the fundamentals of how VMware maps virtual machines to processors/cores. My understanding until now is that VMWare handles everything via it's abstraction layer, there is no direct VM -> Core/Processor mapping, and that shares/affinity only come into play when the host's resources are maxed out. How close to the truth am I?

Appreciate any and all feedback.

Reply
0 Kudos
1 Solution

Accepted Solutions
RParker
Immortal
Immortal
Jump to solution

> Why not putty into your host and run "top" you will see what's utilizing your hosts.

It's actually esxtop. top is for linux but there is a modified version to use in ESX that's preferable.

View solution in original post

Reply
0 Kudos
5 Replies
RH1
Contributor
Contributor
Jump to solution

Whereas servers work mostly with data, virtualizing workstations can be more processor intensive due to the GUI interfaces. Mouse clicks and moves can run up the CPU. Also from the size of the 30 VM's it looks like most of the workstations are in L2 cache so you may be seeing the processor satisfying most requests without the need to go to the physical memory. Your 30 workstations @256k each are only taking up about 7.5gb. Spread that across 3 servers that have 32gbs of memory and they would only use 2.5gbs or less than 10% of your physical memory.

I am running a lot of 2gb and 4gb servers on our farm and using only 19% cpu and over 100% of memory. I wish I had your problem.

williamarrata
Expert
Expert
Jump to solution

Why not putty into your host and run "top" you will see what's utilizing your hosts.

Hope that helped. Smiley Happy

Hope that helped. 🙂
Reply
0 Kudos
mike_laspina
Champion
Champion
Jump to solution

I am working on a brand new ESX 3.5 install. There are 2 quad core 2GHz Xeons in each host, with 3 hosts total. 96MB GB? of RAM overall. Virtual machines will be created as follows:

30 workstations Windows XP SP2 - 20GB HD/256MB/1 vpu

20 Windows 2003 Servers - 15-20GB OS HD/512MB/1 vpu

3 workstations Windows XP SP2- 20GB HD/1GB/1vpu

Hello,

32GB of ram per ESX host is excellent, you could allocate more than 256MB per XP VM and still have plenty free this will help performance because VM,s swap to a file and that can seriously impact performance. I recommend 512 minimum on XP and allocate more where possible on the servers.

The last 3 workstations will be running a graphics-intensive development tool. Running a simulation on one of these VM's takes 3x longer than on a physical machine with a P4 2.8GHz and 2GB RAM. The performance charts show the guest reporting that the CPU is being hit hard, but memory is fine. We upped the VM to 2vpu's and interestingly enough the CPU is not spiking on the charts anymore, although the application is not completeing any faster as it is not multithreaded. Why did the CPU stop spiking on the graph?

Anything that is graphic intensive on a VM will drive the CPU way up. This is because normally the video card GPU performs graphic rendering on the screen. In a VM the CPU must perform this task and also translate it to VNC when you use the console.

Second...my boss insisted that "something is limiting the processor." I told him nothing is limiting the processor because at the moment the host's resources are nowhere near being fully utilized. I added that increasing CPU shares/resource pools won't have an impact on the machine's performance until contention exists. Was I correct?

You are both correct. The Hypervisor works in a manner which allows a thread direct instruction execution on the CPU in a partitioned format. Each partition has limits based on the resources allocated. The CPU is constrained by the nature of the hardware surrounding it, the memory speed, disk access and peripheral bottle necks will be components creating the wait cycles and the CPU will rarely be a bottle neck for the VM.

I am having a difficult time grasping the fundamentals of how VMware maps virtual machines to processors/cores. My understanding until now is that VMWare handles everything via it's abstraction layer, there is no direct VM -> Core/Processor mapping, and that shares/affinity only come into play when the host's resources are maxed out. How close to the truth am I?

That is exactly what it does each thread is abstracted and placed on a vCPU unit to be executed and will not be on any specific core. However you can force it to a core but it will not perform well in most cases when this is done. When the vCPU consumption is nearing max the Hypervisior will calculate what threads are to be executed based on the shares and limits you defined for that VM.

Hope that helps.

http://blog.laspina.ca/ vExpert 2009
RParker
Immortal
Immortal
Jump to solution

> Why not putty into your host and run "top" you will see what's utilizing your hosts.

It's actually esxtop. top is for linux but there is a modified version to use in ESX that's preferable.

Reply
0 Kudos
proden20
Hot Shot
Hot Shot
Jump to solution

"because VM,s swap to a file and that can seriously impact performance."...

I knew this, but thanks for mentioning it. I would not have a problem allocating more RAM to the machines, but first I'd like to know why/how the swap will impact performance. Wouldn't it theoretically be the same as a physical box with 256MB and an HDD swap file? I thought VMWare always created a swap file on the LUN matching your allocated amount of RAM, so no matter what, it was doing some swapping there. I could be way out of the ballpark on that one, though.

Thanks.

Reply
0 Kudos