From mboxrd@z Thu Jan 1 00:00:00 1970 Message-Id: <47D64AD8.5020909@mxp.nes.nec.co.jp> Date: Tue, 11 Mar 2008 18:03:20 +0900 From: Daisuke Nishimura MIME-Version: 1.0 Subject: Re: [PATCH 2/2] Make res_counter hierarchical References: <47D16004.7050204@openvz.org> <20080308134514.434f38f4.kamezawa.hiroyu@jp.fujitsu.com> <47D63FBC.1010805@openvz.org> <20080311173225.937935eb.kamezawa.hiroyu@jp.fujitsu.com> <47D6451A.7090807@openvz.org> In-Reply-To: <47D6451A.7090807@openvz.org> Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org Return-Path: To: Pavel Emelyanov Cc: KAMEZAWA Hiroyuki , Balbir Singh , Paul Menage , Linux Containers , Linux MM List-ID: Hi. > No. The mem_counter_N_limit is the limit for all the memory, that the > Nth group consumes. This includes the RSS, page cache and swap for this > group and all the child groups. Since RSS and page cache are accounted > together, this limit tracks the sum of (memory + swap) values over the > subtree started at the given group. > It seems a bit confusing for me, because current memcg manages only RSS and page cache, not swap. >>>> IMO, a parent's usage is just sum of all childs'. >>>> And, historically, memory overcommit is done agaist "memory usage + swap". >>>> >>>> How about this ? >>>> >>>> >>>> >>>> >>>> >>>> mem_counter_top.usage == sum of all mem_coutner_sub.usage >>>> swap_counter_sub.usage = sum of all swap_counter_sub.usage I prefer Kamezawa-san's idea. Thanks, Daisuke Nishimura. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org