Results 1 to 10 of 10

Thread: KVM CPU Limits

  1. #1
    Join Date
    Feb 2012
    Posts
    23

    Default KVM CPU Limits

    Hello,

    Is it possible to add CPU limits on Proxmox VE 2.x with KVM ?

  2. #2
    Join Date
    Jan 2011
    Posts
    124

    Default Re: KVM CPU Limits

    Quote Originally Posted by CobraHost View Post
    Hello,

    Is it possible to add CPU limits on Proxmox VE 2.x with KVM ?

    Yes

  3. #3
    Join Date
    Feb 2012
    Posts
    23

    Default Re: KVM CPU Limits

    Quote Originally Posted by tylerdurden81 View Post
    Yes
    How do we do this?

  4. #4
    Join Date
    Jan 2011
    Posts
    124

    Default Re: KVM CPU Limits

    When you are creating a VM and it asks about cores .. If you give the VM 1 core .. it can only use one physical core, this is the way I understand it.

  5. #5
    Join Date
    Feb 2012
    Posts
    23

    Default Re: KVM CPU Limits

    Quote Originally Posted by tylerdurden81 View Post
    When you are creating a VM and it asks about cores .. If you give the VM 1 core .. it can only use one physical core, this is the way I understand it.
    That is not limiting the CPU to a certain amount of units or amount per core.

    when we use 100% of 1 core, it raises the CPU usage to around 20% on a 16core AMD CPU.

    XEN/VMware you can limit it to a certain amount of Ghz and that won't happen.
    Last edited by CobraHost; 04-09-2012 at 06:17 PM.

  6. #6
    Join Date
    Jan 2011
    Posts
    124

    Default Re: KVM CPU Limits

    From what I understand you can not limit each cpu. You can add weight to a vm so it has more or less priority over CPU time. This really only comes into play (from what I understand) if the Physical cpu is over a certain usage percent. there is some DOCS about it here http://pve.proxmox.com/pve2-api-doc/ expand nodes, qemu, vmid and click on config then put

  7. #7
    Join Date
    Feb 2012
    Posts
    23

    Default Re: KVM CPU Limits

    Quote Originally Posted by tylerdurden81 View Post
    From what I understand you can not limit each cpu. You can add weight to a vm so it has more or less priority over CPU time. This really only comes into play (from what I understand) if the Physical cpu is over a certain usage percent. there is some DOCS about it here http://pve.proxmox.com/pve2-api-doc/ expand nodes, qemu, vmid and click on config then put
    I'm guessing.

    cpunits: 100 = 10%
    cpuunits: 1000 = 100%

    That is per core ?

  8. #8
    Join Date
    Jan 2011
    Posts
    124

    Default Re: KVM CPU Limits

    No it dosn't work like that. It is weight based on the numbers given to other running VM's

  9. #9
    Join Date
    Feb 2012
    Posts
    23

    Default Re: KVM CPU Limits

    Quote Originally Posted by tylerdurden81 View Post
    No it dosn't work like that. It is weight based on the numbers given to other running VM's
    So we cannot limit single VM using a lot of CPU to 10% ?

    It has to be active on every other VPS.

  10. #10
    Join Date
    Jan 2011
    Posts
    124

    Default Re: KVM CPU Limits

    I suggest you read through the WIKI to understand better. But you can limit a VM to the power of one physical CPU. Not less. Now if the Physical cpu useage gets high you can give some VM's more priority over CPU time. But you can not limit a VM to less power. Now i am not a expert but this is how I understand it.

Bookmarks

Posting Permissions

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