Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp393824ybz; Wed, 29 Apr 2020 02:06:54 -0700 (PDT) X-Google-Smtp-Source: APiQypKhKouoG6K9/0qsJ551n8+NJN+8CCPgc/8gcQgJl5pIusizoz8MqUVbgSKIXFSrN5nrwWkB X-Received: by 2002:a17:906:d9cf:: with SMTP id qk15mr1722439ejb.55.1588151213958; Wed, 29 Apr 2020 02:06:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588151213; cv=none; d=google.com; s=arc-20160816; b=QjzhBNaoOr2IZSLQVukJRZ1STkt9mlDr1HLX6WRDPfbC/N0S5EPLNXvuyZsiRJr4K8 VdUuBah6ZcWPhkblbFFdPqRhx9jTvCDMBSlPQh7Fax9W82MLyuFYZCQ36Cis7OBRnes0 7FoQAxF8d3nqJ8XVO/YBoW/iOkg7PZ12gJxGphOIQ2hyIazze2BvFGplt8vlcC2+Kr/c N1ynwl9HTSEQzJbAVE/4Jk0iRKEZ5WLlV1jKg5c4Hj4sTeTSoFw4vu3LlhAkeA/budME zAaCrlApeZhv8Hd4ZBa2Tr+7EVDCtPXOTGkZiM+MoG7cwh3kRMINxPeLCgQXce8WqEU+ saxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=r/HTkU1bfmWsDb9upjStS+UAKGn53qtpudufPqrt2js=; b=0CZS0POfgbbTpTdQ4v8hDwUED8bBcpAEFror+VwMOvoCVKoVHJ9BDePch4Ftm0/LSn ovjGYVXFSPTXhvWrQ8d9m6ER7geJV8PWa2Q36Bh/kmaEZp8TrmHnouTRAaaijv9E0nAa WncfZTbbs7WFqsSl9/uzRjkEbOrZfE1t6FGMCQghN7GdS40X+e8POKh0fMOErdHFhdjd lVxsjxpM7jz33Ec7sFEg9ysV3Z3A40KuzZbbsAJvzFaaV0uBsuFK+SqcTyFPW2BLNW/A NmUGZFlV3e2l01+OecJoqPUbjlVbcyAqg+WOVhnuF1gB3o3ssT2Upw8FyFjXTDZDdsk5 YXGg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ba9si3099232edb.114.2020.04.29.02.06.29; Wed, 29 Apr 2020 02:06:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726654AbgD2JEn (ORCPT + 99 others); Wed, 29 Apr 2020 05:04:43 -0400 Received: from mail-wr1-f45.google.com ([209.85.221.45]:39667 "EHLO mail-wr1-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726423AbgD2JEn (ORCPT ); Wed, 29 Apr 2020 05:04:43 -0400 Received: by mail-wr1-f45.google.com with SMTP id b11so1540741wrs.6 for ; Wed, 29 Apr 2020 02:04:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=r/HTkU1bfmWsDb9upjStS+UAKGn53qtpudufPqrt2js=; b=eSBLR5or4rhKMpgq+f9TAVrUCOnTqfATbIIrD+ymwgVCUCBHUIvsgYiqfy6M1uH/5q 7ikK0nFTP2EHUEoTPnzzz9V11OqHMOf6y3QZc8gM0NWiZiEUAeC4G43N8aSkBI34T1NF kL5m2bP9pv7kG5sBwlKVNfsDyDT+q1QjZSTMyJfFQwNk1UOVkxqaOGlMOyGlzMpU9Mci qppHyMJIIyc+EX6OV6Iq3V0ETazLmL1tdCmyCHDO73Zd4QDknYxgGm4fqGoiVyHYkAk2 f+J+dADtSrfGnTjPRjMw0asnLFYZH2y4e6W8X5t/Z64NG5IMJPSIS2Rsnb3QZlt+BIVO ZFDQ== X-Gm-Message-State: AGi0PuaMDqKiJuqZW1TBzeaD8oI7yuISKBU/pyNmU27IluvBhVkuZAof 2yc40TY4wbzLg/EdsQQ8QlqBSibd X-Received: by 2002:adf:f704:: with SMTP id r4mr38773099wrp.5.1588151079925; Wed, 29 Apr 2020 02:04:39 -0700 (PDT) Received: from localhost (ip-37-188-130-62.eurotel.cz. [37.188.130.62]) by smtp.gmail.com with ESMTPSA id a9sm6489202wmm.38.2020.04.29.02.04.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Apr 2020 02:04:38 -0700 (PDT) Date: Wed, 29 Apr 2020 11:04:37 +0200 From: Michal Hocko To: Vlastimil Babka Cc: David Rientjes , Tetsuo Handa , Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Mel Gorman Subject: Re: [patch] mm, oom: stop reclaiming if GFP_ATOMIC will start failing soon Message-ID: <20200429090437.GX28637@dhcp22.suse.cz> References: <20200425172706.26b5011293e8dc77b1dccaf3@linux-foundation.org> <20200427133051.b71f961c1bc53a8e72c4f003@linux-foundation.org> <28e35a8b-400e-9320-5a97-accfccf4b9a8@suse.cz> <31f1f84d-c5fe-824b-3c28-1a9ad69fcae5@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <31f1f84d-c5fe-824b-3c28-1a9ad69fcae5@suse.cz> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 29-04-20 09:51:39, Vlastimil Babka wrote: > On 4/28/20 11:48 PM, David Rientjes wrote: > > On Tue, 28 Apr 2020, Vlastimil Babka wrote: > > > > Yes, order-0 reclaim capture is interesting since the issue being reported > > here is userspace going out to lunch because it loops for an unbounded > > amount of time trying to get above a watermark where it's allowed to > > allocate and other consumers are depleting that resource. > > > > We actually prefer to oom kill earlier rather than being put in a > > perpetual state of aggressive reclaim that affects all allocators and the > > unbounded nature of those allocations leads to very poor results for > > everybody. > > Sure. My vague impression is that your (and similar cloud companies) kind of > workloads are designed to maximize machine utilization, and overshooting and > killing something as a result is no big deal. Then you perhaps have more > probability of hitting this state, and on the other hand, even an occasional > premature oom kill is not a big deal? > > My concers are workloads not designed in such a way, where premature oom kill > due to temporary higher reclaim activity together with burst of incoming network > packets will result in e.g. killing an important database. There, the tradeoff > looks different. Completely agreed! The in kernel OOM killer is to deal with situations when memory is desperately depleted without any sign of a forward progress. If there is a reclaimable memory then we are not there yet. If a workload can benefit from early oom killing based on response time then we have facilities to achieve that (e.g. PSI). -- Michal Hocko SUSE Labs