From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8E5E4C4724C for ; Thu, 30 Apr 2020 19:29:21 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4D558207DD for ; Thu, 30 Apr 2020 19:29:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=cmpxchg-org.20150623.gappssmtp.com header.i=@cmpxchg-org.20150623.gappssmtp.com header.b="b4OU7wwb" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4D558207DD Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=cmpxchg.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id C366B8E0005; Thu, 30 Apr 2020 15:29:20 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BBE718E0001; Thu, 30 Apr 2020 15:29:20 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A86A48E0005; Thu, 30 Apr 2020 15:29:20 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0097.hostedemail.com [216.40.44.97]) by kanga.kvack.org (Postfix) with ESMTP id 8D5868E0001 for ; Thu, 30 Apr 2020 15:29:20 -0400 (EDT) Received: from smtpin09.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 46B4F180AD815 for ; Thu, 30 Apr 2020 19:29:20 +0000 (UTC) X-FDA: 76765510080.09.cover71_8bac28cb17419 X-HE-Tag: cover71_8bac28cb17419 X-Filterd-Recvd-Size: 3867 Received: from mail-qt1-f194.google.com (mail-qt1-f194.google.com [209.85.160.194]) by imf43.hostedemail.com (Postfix) with ESMTP for ; Thu, 30 Apr 2020 19:29:19 +0000 (UTC) Received: by mail-qt1-f194.google.com with SMTP id i68so6072061qtb.5 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=HEeh0YxeqOmTRprw+rjfw1pwhjKHfqS6ujo0hk/BV8OT/jIDlPoZT2NIwWuWC82F/0 3oiaKS6r4ajIqztFvqbfEFJXNWAuwCgnbLBx52hf93AI8Bolnd5n2XWPljEJrJI9Sm0p A8Uk1HpSaPBwnhmNaqfA/IoqMuqfoclzlZfl9S4qiBleYsVOqKT5C6MX4xiKIOSpjFK7 CbFYtY7oEDSbqyoBw1x9et/3pZaqGn0QdDLyhN8mm55YrAf7qXJGDEpZ8ml7WBCaIVH6 15rtvqobSNSxfR3Zp+kdDJiGjuyQToQP7Cihd2iqv74uXZ+qmsJICpkwKyr41BVd8kBe 4qIA== X-Gm-Message-State: AGi0PuYKWR5lu9GM+72qoEOu35nFUYoRtoZKpPO/m2noLBW1lPxy/v/0 L1i6WKmzOcyOypCNRwKNKEU8BQ== X-Google-Smtp-Source: APiQypJkMljmJVrYuqw1/FA/joYSeHchiIXs0+3QO3JPks1R2xxvo8ZkpSGPuQBznRyTzHv3YCWvFw== 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> 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: 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.