public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Dan Malek <dan@embeddedalley.com>
Cc: linux-kernel@vger.kernel.org, menage@google.com,
	containers@lists.linux-foundation.org
Subject: Re: [PATCH] Memory usage limit notification addition to memcg
Date: Mon, 13 Apr 2009 16:54:04 -0700	[thread overview]
Message-ID: <20090413165404.b6660aea.akpm@linux-foundation.org> (raw)
In-Reply-To: <298A09AD-495E-4671-84A1-B831826424A8@embeddedalley.com>

On Mon, 13 Apr 2009 16:45:17 -0700
Dan Malek <dan@embeddedalley.com> wrote:

> On Apr 13, 2009, at 4:08 PM, Andrew Morton wrote:
> 
> > We've run into problems in the past where a percentage number is too
> > coarse on large-memory systems.
> >
> > Proabably that won't be an issue here, but I invite you to convince us
> > of this ;)
> 
> The challenge here is that the absolute limit of the memcg can
> be dynamically changed, so I wanted to avoid a couple of problems.
> One is just a system configuration error where someone forgets
> to modify both.  For example, if you start with the memcg limit of 100M,
> and the notification limit to 80M, then come back and change the memcg
> limit to 90M (or worse, < 80M) you now have a clearly incorrect
> configuration.   Another problem is the operation isn't atomic, at some
> point during the changes, even if you remember to do it correctly, you
> will have the two values not representing what you really want.  It
> could trigger an erroneous notification, or simply OOM kill before you
> get the configuration correct.
> 
> If an integer number turns out to not be sufficient, we could change  
> this
> to some fixed point representation and adjust the arithmetic in the  
> tests.
> I believe the integer number will be fine, even in large memory systems.
> This is just a notification model, if we want something more fine  
> grained
> I believe it would need different semantics.

I agree.  But it would be a mighty mess if we were to turn around in
two years time and add a second centi-percent interface.  So we should
give this careful thought now and really convince ourselves that we
will never ever ever want sub-1% resolution.



  reply	other threads:[~2009-04-13 23:57 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-13 22:08 [PATCH] Memory usage limit notification addition to memcg Dan Malek
2009-04-13 23:08 ` Andrew Morton
2009-04-13 23:45   ` Dan Malek
2009-04-13 23:54     ` Andrew Morton [this message]
2009-04-14  0:52       ` Dan Malek
2009-04-15  0:35 ` KAMEZAWA Hiroyuki
2009-04-15  2:34   ` Dan Malek
2009-04-15  2:58     ` KAMEZAWA Hiroyuki
2009-04-15  7:32       ` Dan Malek
2009-04-15  7:33         ` KAMEZAWA Hiroyuki
2009-04-15  8:24   ` Balbir Singh
2009-04-15 17:35     ` Dan Malek
2009-04-16  3:15       ` Balbir Singh
2009-07-07 20:25 ` [PATCH 0/1] " Vladislav Buzov
2009-07-07 20:25   ` [PATCH 1/1] " Vladislav Buzov
2009-07-08  0:56     ` KAMEZAWA Hiroyuki
2009-07-09  1:43       ` Vladislav D. Buzov
2009-07-13  0:52         ` KAMEZAWA Hiroyuki
2009-07-13 21:21           ` Vladislav D. Buzov
2009-07-13 22:15       ` Paul Menage
2009-07-14  1:00         ` Vladislav D. Buzov
2009-07-14  1:03           ` KAMEZAWA Hiroyuki
2009-07-14  1:43         ` KOSAKI Motohiro
2009-07-14 19:13           ` Dan Malek
2009-07-16 17:15             ` Balbir Singh
2009-07-16 18:16               ` Dan Malek
2009-07-17  2:33                 ` Balbir Singh
2009-07-15  6:02         ` Balbir Singh
2009-07-08  3:52     ` Balbir Singh
2009-07-10 18:01       ` Vladislav D. Buzov
2009-07-14  0:16   ` [PATCH 0/2] Memory usage limit notification feature (v3) Vladislav Buzov
2009-07-14  0:16     ` [PATCH 1/2] Resource usage threshold notification addition to res_counter (v3) Vladislav Buzov
2009-07-14  0:16       ` [PATCH 2/2] Memory usage limit notification addition to memcg (v3) Vladislav Buzov
2009-07-14  0:30       ` [PATCH 1/2] Resource usage threshold notification addition to res_counter (v3) KAMEZAWA Hiroyuki
2009-07-14  1:29         ` Vladislav D. Buzov
2009-07-14  1:45           ` KAMEZAWA Hiroyuki
2009-07-14  0:36       ` Paul Menage
2009-07-14  0:47         ` KAMEZAWA Hiroyuki
2009-07-14  0:20     ` [PATCH 0/2] Memory usage limit notification feature (v3) Paul Menage
2009-07-14  0:31       ` KOSAKI Motohiro

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=20090413165404.b6660aea.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=containers@lists.linux-foundation.org \
    --cc=dan@embeddedalley.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=menage@google.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox