Find the answer to your Linux question:
Results 1 to 3 of 3
Hello, I have an Ubuntu server system on which i want to run multiple virtual machines. But some VMs are more important than others, and i wish to guarantee them ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Feb 2010
    Posts
    1

    Dividing cpu cycles between processes


    Hello,

    I have an Ubuntu server system on which i want to run multiple virtual machines.
    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 get 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

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,639
    This is a matter for the scheduler. There are several available for Linux, and which is used by a particular virtual machine manager such as VirtualBox is up to the VMM. VirtualBox uses the standard system scheduler, so you should be able to renice a running VM to a higher priority than the others. You'll need to do some experimenting to find what works best for you.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,639
    BTW, the lower the nice factor (some number < 0), the higher the priority of the process.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •