From patchwork Tue Feb 25 14:15:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mel Gorman X-Patchwork-Id: 11403957 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id CE277930 for ; Tue, 25 Feb 2020 14:15:40 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A4763218AC for ; Tue, 25 Feb 2020 14:15:40 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A4763218AC Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=techsingularity.net Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E36EF6B0006; Tue, 25 Feb 2020 09:15:39 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id DE7226B0007; Tue, 25 Feb 2020 09:15:39 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CD8656B0008; Tue, 25 Feb 2020 09:15:39 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0188.hostedemail.com [216.40.44.188]) by kanga.kvack.org (Postfix) with ESMTP id B5EF76B0006 for ; Tue, 25 Feb 2020 09:15:39 -0500 (EST) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 67174824556B for ; Tue, 25 Feb 2020 14:15:39 +0000 (UTC) X-FDA: 76528847598.20.ship88_141eda02a7c4e X-Spam-Summary: 2,0,0,43a991f2c45ab5b4,d41d8cd98f00b204,mgorman@techsingularity.net,,RULES_HIT:41:69:355:379:541:966:973:988:989:1260:1345:1437:1534:1541:1711:1730:1747:1777:1792:2196:2199:2393:2559:2562:3138:3139:3140:3141:3142:3352:3834:3865:3866:3867:3868:3870:3871:3872:3874:4250:4385:4560:4605:5007:6119:6261:6630:7903:7904:8634:10004:11537:11658:11914:12043:12198:12291:12297:12517:12519:12522:12555:12660:12683:12895:13069:13153:13161:13228:13229:13311:13357:14095:14096:14384:14394:14721:21080:21324:21451:21627:21795:21966:30051:30054:30060,0,RBL:81.17.249.11:@techsingularity.net:.lbl8.mailshell.net-64.201.201.201 62.14.114.100,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fp,MSBL:0,DNSBL:neutral,Custom_rules:0:0:0,LFtime:26,LUA_SUMMARY:none X-HE-Tag: ship88_141eda02a7c4e X-Filterd-Recvd-Size: 2606 Received: from outbound-smtp28.blacknight.com (outbound-smtp28.blacknight.com [81.17.249.11]) by imf01.hostedemail.com (Postfix) with ESMTP for ; Tue, 25 Feb 2020 14:15:37 +0000 (UTC) Received: from mail.blacknight.com (pemlinmail05.blacknight.ie [81.17.254.26]) by outbound-smtp28.blacknight.com (Postfix) with ESMTPS id D46F3CCA71 for ; Tue, 25 Feb 2020 14:15:35 +0000 (GMT) Received: (qmail 1851 invoked from network); 25 Feb 2020 14:15:35 -0000 Received: from unknown (HELO stampy.112glenside.lan) (mgorman@techsingularity.net@[84.203.18.57]) by 81.17.254.9 with ESMTPA; 25 Feb 2020 14:15:35 -0000 From: Mel Gorman To: Andrew Morton Cc: Michal Hocko , Vlastimil Babka , Ivan Babrou , Rik van Riel , Linux-MM , Linux Kernel Mailing List , Mel Gorman Subject: [PATCH 0/3] Limit runaway reclaim due to watermark boosting Date: Tue, 25 Feb 2020 14:15:31 +0000 Message-Id: <20200225141534.5044-1-mgorman@techsingularity.net> X-Mailer: git-send-email 2.16.4 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Ivan Babrou reported the following Commit 1c30844d2dfe ("mm: reclaim small amounts of memory when an external fragmentation event occurs") introduced undesired effects in our environment. * NUMA with 2 x CPU * 128GB of RAM * THP disabled * Upgraded from 4.19 to 5.4 Before we saw free memory hover at around 1.4GB with no spikes. After the upgrade we saw some machines decide that they need a lot more than that, with frequent spikes above 10GB, often only on a single numa node. There have been a few reports recently that might be watermark boost related. Unfortunately, finding someone that can reproduce the problem and test a patch has been problematic. This series intends to limit potential damage only. Patch 1 disables boosting on small memory systems. Patch 2 disables boosting by default if THP is disabled on the kernel command line on the basis that boosting primarily helps THP allocation latency. It is not touched at runtime to avoid overriding an explicit user request Patch 3 disables boosting if kswapd priority is elevateed to avoid excessive reclaim. mm/huge_memory.c | 1 + mm/internal.h | 6 +++++- mm/page_alloc.c | 6 ++++-- mm/vmscan.c | 46 +++++++++++++++++++++++++++++++--------------- 4 files changed, 41 insertions(+), 18 deletions(-)