LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Virtualization and Cloud (https://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/)
-   -   Dividing cpu time between Virtual Machines (https://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/dividing-cpu-time-between-virtual-machines-789532/)

spin_ro 02-16-2010 12:58 PM

Dividing cpu time between Virtual Machines
 
Hello,

I have an Ubuntu server system on which i want to run multiple virtual machines (VMware Server).
But some VMs are more important than others, and i wish to guarantee them a minimum cpu access (if they need it).

example 1 : if there were 2 VMs, i would like to be able to grant one of them a number of cpu cycles 4 times greater. Also, if one of the machines isn't using all it's allocated cpu time, the other one must be able to use it.
example 2 more complex : if i have N VMs, i want to be able to set for each VM a minimum % of cpu usage. But if a VM doesn't need it, another VM can use it. This way, every VM gets at least the % indicated, but can receive more if the other VMs are not using their time.

I know about 'cpulimit' , but it only knows how to set an upper limit. I need something that is flexible at the upper part.

Does anyone have a solution for this ?
Thanks in advance :)
andrei

scheidel21 02-17-2010 07:24 AM

At least with VMWare Server I am not aware of a way to do this.

neonsignal 02-17-2010 07:40 AM

The ESX versions allow control of both reserved CPU (measured in MHz rather than percentage), and a limit. However, I don't think this is available in the Server version.

You can of course control the priorities of VMs (either from the vmx configuration, or simply by using the nice levels in Linux). But that doesn't give any guarantee of a minimum CPU percentage, since higher priority tasks will get preference.


All times are GMT -5. The time now is 11:48 AM.