Solved

Can a vm with 1 vCPU use more CPU computing resources than entitled during CPU-intensive spikes?

Posted on 2014-09-19
5
336 Views
Last Modified: 2014-09-19
So my boss asked a question today that I did not know the answer to offhand. I am not a certified VMWare VCP, etc so I apologize if this is a dumb question. Here goes:

Say I have a VM that is assigned 1 vCPU. Given that the cores of the pCPU are 2GHz, what would happen if the VM suddenly ran at max CPU utilization for a relatively sustained period? For instance, the VM requires 2.5GHz of processing power for 5 minutes. Is there a feature in vSphere that would allow that VM to "steal" some CPU cycles from the pool of CPU resources on the host in order to not be maxed out for those 5 minutes?

We have VMs that typically barely bump 1 vCPU, but on occasion, they may get hammered by some sustained CPU intensive process. As such we don't want to have to permanently assign 2 vCPUs to these VMs and have them sit barely above 1% for the majority of the time when they only really require those resources for short, heavy bursts. Is there a way to make this work?

Thanks,
JAK
0
Comment
Question by:SimplyGeeky
  • 3
  • 2
5 Comments
 
LVL 118

Accepted Solution

by:
Andrew Hancock (VMware vExpert / EE MVE) earned 500 total points
ID: 40333573
When you assign 1 vCPU (socket) in the VM, it's allocated against 1 core of the physical hosts processor, if the physical core is 2GHz, the vCPU MAX is 2000 clock cycles.

This is simplified, because this process, is time sliced across all the cores in the physical host, so the assigned vCPU to physical Core, may not be the same core throughout the process.

Your VM can only use the resources it has been assigned, it cannot use more than what is has been assigned, e.g. DYNAMIC CPU MHz does not exist.

You will find that your VM, should be MAX OUT (CPU) for 5 minutes, so I would give it another vCPU (if it needs it!).

Assign another vCPU.
0
 
LVL 61

Expert Comment

by:gheist
ID: 40333617
First it will use cores on one socket, then add cores on next socket, and in the end hyperthreads (count all the VCPUs running in full)
Once you exceed 2 completely loaded vCPUs per core it becomes visibly slower for interactive users.
But you really need enormous amounts of RAM to get there.
2 vcpus is good minimum for any system. One archaic runaway process will not hurt your system (example: Antivirus)
0
 
LVL 61

Expert Comment

by:gheist
ID: 40333762
Indeed dynamic CPU MHZ do exist called turbo mode...
0
 
LVL 118
ID: 40333784
We don't yet have them in the virtual world.....

e.g. like dynamic memory in Hyper-V!

Maybe Hot Add, but it's not automatic!
0
 
LVL 61

Expert Comment

by:gheist
ID: 40333811
Outside VM you see more than nominal GHz per vCPU, and inside VM you can detect it with linux turbostat...
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

HOW TO: Install and Configure VMware vSphere Hypervisor 6.5 (ESXi 6.5), Step by Step Tutorial with screenshots. From Download, Checking Media, to Completed Installation.
In this article, I will show you HOW TO: Install VMware Tools for Windows on a VMware Windows virtual machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, using the VMware Host Client. The virtual machine has Windows Server 2016 instal…
Teach the user how to delpoy the vCenter Server Appliance and how to configure its network settings Deploy OVF: Open VM console and configure networking:
This Micro Tutorial walks you through using a remote console to access a server and install ESXi 5.1. This example is showing remote access and installation using a Dell server. The hypervisor is the very first component of your virtual infrastructu…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now