Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp2192216ybz; Thu, 30 Apr 2020 12:31:14 -0700 (PDT) X-Google-Smtp-Source: APiQypKA9/cM04/xAjIghKBQ6qBId/LpRVSuVRiyg6mH9gmHjL6aC6Jx4RIjLkeOMKB3roDLP9aH X-Received: by 2002:a17:906:6990:: with SMTP id i16mr4134171ejr.175.1588275074102; Thu, 30 Apr 2020 12:31:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588275074; cv=none; d=google.com; s=arc-20160816; b=KxhiO+PGaA/BpVb5Trd4CSMrNiSdHZYYnZ73ZnhyGP71gz/XNwkY3wwJpQ66SQm80T +RPVXaSXabEzn1u53i/nXOcVRWOhWbzmc6TI8MKipr7B4lISI33UT0stRL7MlTsudk6z dxS3EmL9TfiZLNhC8sS24AFvk05aBog3bW4VFz8Me6hVr+PhwLDgAtFernRjop4yiHZw 1CXqFeM+mj8gxDboT4fHkcQm+78uuvn7GsrNfnkapmmwF1qsl8L7LbDSzDYmrdqVTUGN 9KLi53uWOiC4G0bJzl0Jp0MAI7I02LlYwlnCg9ZBs/F3VKyuMkWPEO+z3sDJgqDoy+Rd ZERA== 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 :dkim-signature; bh=/eq6aHDyq4eplML2a4cRLGlwq126IAji+Fvgv3MjJ3w=; b=UzBmJuYS9LebEEToubvyvjJshZM4aHFx8W4d818q6xUrOgh/7G96x0F9uDSwwgq5EY lEyQHh0bVwikMaL7Y9TFhXRoYs6MGWNAW94s7ucBrlHKGOBcLkv6ah5hlqnqoQJgFKvc a0ZJPh/bs/SVGIMPNyrkXhN6LwN0TKHG5VCDHjVwzB2C3RPfxQCgwWU41R987AN57Ft+ 58qJMb6BTwqEIAn29MzezHUFwmIP8MjAQzzZXwM7Wx80cmeEp4pS6gY5iJvcuWsxreV0 XiwrCqx2IVZDk6l/yKNYYQw0YSK1aD0lzxh1wEc/95W6BIWtSDZYsuy8PESvkZuue/Le TSdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cmpxchg-org.20150623.gappssmtp.com header.s=20150623 header.b=b4OU7wwb; 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=fail (p=NONE sp=NONE dis=NONE) header.from=cmpxchg.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dd22si325978edb.162.2020.04.30.12.30.49; Thu, 30 Apr 2020 12:31:14 -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; dkim=pass header.i=@cmpxchg-org.20150623.gappssmtp.com header.s=20150623 header.b=b4OU7wwb; 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=fail (p=NONE sp=NONE dis=NONE) header.from=cmpxchg.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726593AbgD3T3U (ORCPT + 99 others); Thu, 30 Apr 2020 15:29:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726396AbgD3T3T (ORCPT ); Thu, 30 Apr 2020 15:29:19 -0400 Received: from mail-qt1-x844.google.com (mail-qt1-x844.google.com [IPv6:2607:f8b0:4864:20::844]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A9F8AC035494 for ; Thu, 30 Apr 2020 12:29:19 -0700 (PDT) Received: by mail-qt1-x844.google.com with SMTP id b1so6088088qtt.1 for ; Thu, 30 Apr 2020 12:29:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpxchg-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=/eq6aHDyq4eplML2a4cRLGlwq126IAji+Fvgv3MjJ3w=; b=b4OU7wwbA3wxPurcG9pIX2GntI2Xn9noV/RldtqK/ry2Aih34RZFyG37mvEUhqPgUJ FZuolZ4rblAdaMTfLS/iPurKZ2F/6LgIKXT/SPaEjMRd+QYwp0iY0BM+tlLBA7fvDX0b PoKDmL7E0sHYEdt3HL88joyXkVl1giGBlW/wGc0A4Z+11ui4tXTZR9v+/zrk6N9GA6vQ haEP1z4FLxKtLHf0Jh1JXqAuHFmIlunGDsdbG4opwBuPEkRLvy8YZ6HWRP9GmVpISVqB FH581z7KqQk9BGUSOLm3k9zUxr+9oN1hYP+uY2Iia++2Azdeu1TiYpS2K1o6nZxcsaMj dT1A== 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=/eq6aHDyq4eplML2a4cRLGlwq126IAji+Fvgv3MjJ3w=; b=B0+9ypvBAXJXAlq0FMLy5gsbskxn1+/BBgQvT/dOb1aI2jDrqln27Yc4rTccCEE6z5 jr14O9rRnuVjJFiZy9NmhVqdAcaGYvZwt/DekCQVLKFqD0N57udHhmr3HSw+sF0Jq4n6 1edwuy8dXl7l12adWqRb+UNc3ZSlWXEjhU9AuE1lqOLWB66g7fUvJ9xKDGT7DWvYqwkM 1h5c+NNdkh86XS6RHuHXHNDEe865a1IMT4LenBZ9sxgy/hIkOlmsD0bjlCQy+Ywg+jDD s8X7rEmCsQS/8YW/YmdwfYtl4i5XVo6HTR9mY/jyRVOFthdiPR9sPojQ2mTaOdvZpeT9 aRfQ== X-Gm-Message-State: AGi0PuZZCeN4NV1b1pQM2mBBKsfiUsRf6/EeXoNd+spBCzK/eyq2HcHi vQh8UYmKtQx99fnYdM+eUHKfQQ== X-Received: by 2002:ac8:1885:: with SMTP id s5mr2430qtj.253.1588274958913; Thu, 30 Apr 2020 12:29:18 -0700 (PDT) Received: from localhost ([2620:10d:c091:480::1:63a7]) by smtp.gmail.com with ESMTPSA id u27sm543996qtc.73.2020.04.30.12.29.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Apr 2020 12:29:18 -0700 (PDT) Date: Thu, 30 Apr 2020 15:29:07 -0400 From: Johannes Weiner To: Shakeel Butt Cc: Roman Gushchin , Michal Hocko , Greg Thelen , Andrew Morton , linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] memcg: oom: ignore oom warnings from memory.max Message-ID: <20200430192907.GA2436@cmpxchg.org> References: <20200430182712.237526-1-shakeelb@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200430182712.237526-1-shakeelb@google.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 30, 2020 at 11:27:12AM -0700, Shakeel Butt wrote: > Lowering memory.max can trigger an oom-kill if the reclaim does not > succeed. However if oom-killer does not find a process for killing, it > dumps a lot of warnings. > > Deleting a memcg does not reclaim memory from it and the memory can > linger till there is a memory pressure. One normal way to proactively > reclaim such memory is to set memory.max to 0 just before deleting the > memcg. However if some of the memcg's memory is pinned by others, this > operation can trigger an oom-kill without any process and thus can log a > lot un-needed warnings. So, ignore all such warnings from memory.max. Can't you set memory.high=0 instead? It does the reclaim portion of memory.max, without the actual OOM killing that causes you problems.