All of lore.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Paul Menage <menage@google.com>
Cc: bharata@linux.vnet.ibm.com, linux-kernel@vger.kernel.org,
	Dhaval Giani <dhaval@linux.vnet.ibm.com>,
	Balbir Singh <balbir@linux.vnet.ibm.com>,
	Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>,
	Gautham R Shenoy <ego@in.ibm.com>,
	Srivatsa Vaddagiri <vatsa@in.ibm.com>,
	Ingo Molnar <mingo@elte.hu>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Pavel Emelyanov <xemul@openvz.org>,
	kvm@vger.kernel.org,
	Linux Containers <containers@lists.linux-foundation.org>,
	Herbert Poetzl <herbert@13thfloor.at>
Subject: Re: [RFC] CPU hard limits
Date: Fri, 05 Jun 2009 16:02:11 +0300	[thread overview]
Message-ID: <4A291753.7090205@redhat.com> (raw)
In-Reply-To: <6599ad830906050153i1afd104fqe70f681317349142@mail.gmail.com>

Paul Menage wrote:
> On Wed, Jun 3, 2009 at 10:36 PM, Bharata B
> Rao<bharata@linux.vnet.ibm.com> wrote:
>   
>> - Hard limits can be used to provide guarantees.
>>
>>     
>
> This claim (and the subsequent long thread it generated on how limits
> can provide guarantees) confused me a bit.
>
> Why do we need limits to provide guarantees when we can already
> provide guarantees via shares?
>
> Suppose 10 cgroups each want 10% of the machine's CPU. We can just
> give each cgroup an equal share, and they're guaranteed 10% if they
> try to use it; if they don't use it, other cgroups can get access to
> the idle cycles.
>
> Suppose cgroup A wants a guarantee of 50% and two others, B and C,
> want guarantees of 15% each; give A 50 shares and B and C 15 shares
> each. In this case, if they all run flat out they'll get 62%/19%/19%,
> which is within their SLA.
>
> That's not to say that hard limits can't be useful in their own right
> - e.g. for providing reproducible loadtesting conditions by
> controlling how much CPU a service can use during the load test. But I
> don't see why using them to implement guarantees is either necessary
> or desirable.
>
> (Unless I'm missing some crucial point ...)
>   

How many shares does a cgroup with a 0% guarantee get?

Ideally, the scheduler would hand out cpu time according to weight and 
demand, then clamp over-demand by a cgroup's limit and boost the share 
to meet guarantees.

-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.


  parent reply	other threads:[~2009-06-05 13:04 UTC|newest]

Thread overview: 107+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-04  5:36 [RFC] CPU hard limits Bharata B Rao
2009-06-04 12:19 ` Avi Kivity
2009-06-04 21:32   ` Mike Waychison
     [not found]   ` <4A27BBCA.5020606-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-04 21:32     ` Mike Waychison
2009-06-05  3:03     ` Bharata B Rao
2009-06-05  3:07     ` Balbir Singh
2009-06-05  3:03   ` Bharata B Rao
     [not found]     ` <20090605030309.GA3872-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-05  3:33       ` Avi Kivity
2009-06-05  3:33     ` Avi Kivity
     [not found]       ` <4A28921C.6010802-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  4:37         ` Balbir Singh
2009-06-05  4:37       ` Balbir Singh
2009-06-05  4:44         ` Avi Kivity
2009-06-05  4:49           ` Balbir Singh
2009-06-05  5:09             ` Chris Friesen
2009-06-05  5:13               ` Balbir Singh
     [not found]               ` <4A28A882.8070503-ZIRUuHA3oDzQT0dZR+AlfA@public.gmane.org>
2009-06-05  5:13                 ` Balbir Singh
2009-06-05  5:10             ` Balbir Singh
2009-06-05  5:21               ` Avi Kivity
2009-06-05  5:27                 ` Balbir Singh
2009-06-05  5:31                   ` Bharata B Rao
     [not found]                     ` <20090605053159.GB3872-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-05  6:01                       ` Avi Kivity
2009-06-05  9:24                       ` Balbir Singh
2009-06-05  6:01                     ` Avi Kivity
     [not found]                       ` <4A28B4CE.4010004-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  8:16                         ` Bharata B Rao
2009-06-05  8:16                           ` Bharata B Rao
     [not found]                           ` <20090605081651.GD3872-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-07  6:04                             ` Avi Kivity
2009-06-07  6:04                           ` Avi Kivity
2009-06-07 16:14                             ` Bharata B Rao
     [not found]                             ` <4A2B5881.9060204-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-07 16:14                               ` Bharata B Rao
2009-06-05  9:39                         ` Balbir Singh
2009-06-05  9:39                       ` Balbir Singh
     [not found]                         ` <20090605093947.GJ11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05 13:14                           ` Avi Kivity
2009-06-05 13:14                         ` Avi Kivity
2009-06-05 14:54                           ` Chris Friesen
2009-06-07  6:10                             ` Avi Kivity
     [not found]                             ` <4A293196.2060006-ZIRUuHA3oDzQT0dZR+AlfA@public.gmane.org>
2009-06-07  6:10                               ` Avi Kivity
     [not found]                           ` <4A291A2F.3090201-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05 13:42                             ` Balbir Singh
2009-06-05 13:42                               ` Balbir Singh
2009-06-07  6:09                               ` Avi Kivity
     [not found]                               ` <661de9470906050642s7774d601l53e366c77ffa7475-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-07  6:09                                 ` Avi Kivity
2009-06-05 14:54                             ` Chris Friesen
2009-06-05  9:24                     ` Balbir Singh
2009-06-05  6:03                   ` Avi Kivity
2009-06-05  6:32                     ` Bharata B Rao
2009-06-05 12:57                       ` Avi Kivity
     [not found]                       ` <20090605063243.GC3872-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-05 12:57                         ` Avi Kivity
     [not found]                     ` <4A28B539.3050001-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  6:32                       ` Bharata B Rao
     [not found]                   ` <20090605052755.GE11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05  5:31                     ` Bharata B Rao
2009-06-05  6:03                     ` Avi Kivity
     [not found]                 ` <4A28AB67.7040800-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  5:27                   ` Balbir Singh
     [not found]               ` <20090605051050.GB11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05  5:21                 ` Avi Kivity
     [not found]             ` <20090605044946.GA11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05  5:09               ` Chris Friesen
2009-06-05  5:10               ` Balbir Singh
2009-06-05  5:16               ` Avi Kivity
2009-06-05  5:16             ` Avi Kivity
     [not found]               ` <4A28AA25.4050206-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  5:20                 ` Balbir Singh
2009-06-05  5:20               ` Balbir Singh
     [not found]           ` <4A28A2AB.3060108-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05  4:49             ` Balbir Singh
     [not found]         ` <661de9470906042137u603e2997n80c270bf7f6191ad-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-05  4:44           ` Avi Kivity
2009-06-05  3:07   ` Balbir Singh
     [not found] ` <20090604053649.GA3701-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-04 12:19   ` Avi Kivity
2009-06-05  8:53   ` Paul Menage
2009-06-05  8:53 ` Paul Menage
2009-06-05  9:27   ` Bharata B Rao
2009-06-05  9:32     ` Paul Menage
2009-06-05  9:48       ` Dhaval Giani
     [not found]         ` <20090605094811.GD4601-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2009-06-05  9:51           ` Paul Menage
2009-06-05  9:51         ` Paul Menage
2009-06-05  9:59           ` Dhaval Giani
2009-06-05 10:03             ` Paul Menage
     [not found]               ` <6599ad830906050303r404c325anc60ded4f45a50b95-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-08  8:50                 ` Pavel Emelyanov
2009-06-08  8:50               ` Pavel Emelyanov
     [not found]             ` <20090605095931.GE4601-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2009-06-05 10:03               ` Paul Menage
     [not found]           ` <6599ad830906050251h18f4e037h182f61aa80a5b046-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-05  9:59             ` Dhaval Giani
     [not found]       ` <6599ad830906050232n11aa30d8xfcda0a279a482f32-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-05  9:48         ` Dhaval Giani
     [not found]     ` <20090605092733.GA27486-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-05  9:32       ` Paul Menage
     [not found]   ` <6599ad830906050153i1afd104fqe70f681317349142-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-05  9:27     ` Bharata B Rao
2009-06-05  9:36     ` Balbir Singh
2009-06-05 11:32     ` Srivatsa Vaddagiri
2009-06-05 13:02     ` Avi Kivity
2009-06-05  9:36   ` Balbir Singh
     [not found]     ` <20090605093625.GI11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05  9:48       ` Paul Menage
2009-06-05  9:48         ` Paul Menage
2009-06-05  9:55         ` Balbir Singh
2009-06-05  9:57           ` Paul Menage
     [not found]           ` <20090605095527.GM11755-SINUvgVNF2CyUtPGxGje5AC/G2K4zDHf@public.gmane.org>
2009-06-05  9:57             ` Paul Menage
2009-06-05 10:02             ` Paul Menage
2009-06-05 10:02           ` Paul Menage
     [not found]         ` <6599ad830906050248m2c569e5bx44fb3bbddf46f8b1-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-05  9:55           ` Balbir Singh
2009-06-05 11:32   ` Srivatsa Vaddagiri
2009-06-05 12:18     ` Paul Menage
     [not found]       ` <6599ad830906050518t6cd7d477h36a187f2eaf55578-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-07 10:11         ` Srivatsa Vaddagiri
2009-06-07 10:11           ` Srivatsa Vaddagiri
     [not found]           ` <20090607101120.GB16211-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-07 15:35             ` Balbir Singh
2009-06-07 15:35           ` Balbir Singh
     [not found]             ` <661de9470906070835l383cd388h67e40a31be07aef6-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-06-08  4:37               ` Srivatsa Vaddagiri
2009-06-08  4:37             ` Srivatsa Vaddagiri
     [not found]     ` <20090605113217.GA20786-xthvdsQ13ZrQT0dZR+AlfA@public.gmane.org>
2009-06-05 12:18       ` Paul Menage
2009-06-05 14:44       ` Chris Friesen
2009-06-05 14:44     ` Chris Friesen
2009-06-05 13:02   ` Avi Kivity [this message]
     [not found]     ` <4A291753.7090205-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-06-05 13:43       ` Dhaval Giani
2009-06-05 13:43     ` Dhaval Giani
2009-06-05 14:45       ` Chris Friesen
     [not found]       ` <20090605134320.GA3994-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2009-06-05 14:45         ` Chris Friesen
2009-06-05  9:02 ` Reinhard Tartler
  -- strict thread matches above, loose matches on Subject: below --
2009-06-04  5:36 Bharata B Rao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4A291753.7090205@redhat.com \
    --to=avi@redhat.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=balbir@linux.vnet.ibm.com \
    --cc=bharata@linux.vnet.ibm.com \
    --cc=containers@lists.linux-foundation.org \
    --cc=dhaval@linux.vnet.ibm.com \
    --cc=ego@in.ibm.com \
    --cc=herbert@13thfloor.at \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=menage@google.com \
    --cc=mingo@elte.hu \
    --cc=svaidy@linux.vnet.ibm.com \
    --cc=vatsa@in.ibm.com \
    --cc=xemul@openvz.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.