From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tejun Heo Subject: Re: [RFC] Making memcg track ownership per address_space or anon_vma Date: Thu, 5 Feb 2015 17:25:22 -0500 Message-ID: <20150205222522.GA10580@htj.dyndns.org> References: <20150130062737.GB25699@htj.dyndns.org> <20150130160722.GA26111@htj.dyndns.org> <54CFCF74.6090400@yandex-team.ru> <20150202194608.GA8169@htj.dyndns.org> <20150204170656.GA18858@htj.dyndns.org> <20150205131514.GD25736@htj.dyndns.org> Mime-Version: 1.0 Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=IzC42CtKuf3buTw4WUxm98Uwgqy2e4TneHYq4Re4n54=; b=mRYVmgCcsYvD3/a60nd7BkQ3eranZM7i6m1coOUzwioTLAmtoy/jcy3FQTt0A4/Bi6 I7/Rizl1/u/DZeoQcFrI7s6Vovtcl/bNFna7pZY5TRJj8Qa68nMulrnk0nBBHnAKiLAd vLz3DabcyR2tA0iuIUKcZoViFxvu9AaVVnEBkoWTC48txQLOo+upL31sag/M9S77IwNq iBqKBxZyOW4FEgGHJ8MIR0wZxchJ6jenrvF8hs7wgaaxDQsYSMmWhIDOzfW+a9i4vnom CaABtxjGCP7lUvmgsohcEe1ht8kQRe3y06Z0Klu1BtBB0812iaYSJZRp3vvcsBxfyi0Q xnlQ== Content-Disposition: inline In-Reply-To: Sender: cgroups-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Greg Thelen Cc: Konstantin Khlebnikov , Johannes Weiner , Michal Hocko , Cgroups , "linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org" , "linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , Jan Kara , Dave Chinner , Jens Axboe , Christoph Hellwig , Li Zefan , Hugh Dickins Hey, On Thu, Feb 05, 2015 at 02:05:19PM -0800, Greg Thelen wrote: > > A > > +-B (usage=2M lim=3M min=2M hosted_usage=2M) > > +-C (usage=0 lim=2M min=1M shared_usage=2M) > > +-D (usage=0 lim=2M min=1M shared_usage=2M) > > \-E (usage=0 lim=2M min=0) ... > Maybe, but I want to understand more about how pressure works in the > child. As C (or D) allocates non shared memory does it perform reclaim > to ensure that its (C.usage + C.shared_usage < C.lim). Given C's Yes. > shared_usage is linked into B.LRU it wouldn't be naturally reclaimable > by C. Are you thinking that charge failures on cgroups with non zero > shared_usage would, as needed, induce reclaim of parent's hosted_usage? Hmmm.... I'm not really sure but why not? If we properly account for the low protection when pushing inodes to the parent, I don't think it'd break anything. IOW, allow the amount beyond the sum of low limits to be reclaimed when one of the sharers is under pressure. Thanks. -- tejun