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=-1.0 required=3.0 tests=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 69E84C3815B for ; Mon, 20 Apr 2020 11:10:18 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 33BC420724 for ; Mon, 20 Apr 2020 11:10:18 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 33BC420724 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id A8AE48E0005; Mon, 20 Apr 2020 07:10:17 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id A3B028E0003; Mon, 20 Apr 2020 07:10:17 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9508A8E0005; Mon, 20 Apr 2020 07:10:17 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0117.hostedemail.com [216.40.44.117]) by kanga.kvack.org (Postfix) with ESMTP id 7C0F98E0003 for ; Mon, 20 Apr 2020 07:10:17 -0400 (EDT) Received: from smtpin23.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id 2C0F5181AEF39 for ; Mon, 20 Apr 2020 11:10:17 +0000 (UTC) X-FDA: 76727964474.23.food78_2720025bca3f X-HE-Tag: food78_2720025bca3f X-Filterd-Recvd-Size: 3857 Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by imf45.hostedemail.com (Postfix) with ESMTP for ; Mon, 20 Apr 2020 11:10:16 +0000 (UTC) Received: by mail-wr1-f65.google.com with SMTP id k1so11627219wrx.4 for ; Mon, 20 Apr 2020 04:10:16 -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=JJ6gwIZLSb3ftA73zaYTli6Q+/OdLPIjNGI7Si5l7Tc=; b=HE0ppQKng3Sjc+UjQKhg9/zw4mH9dA2vRogZC6fvwCR7m6zvqbw9yjZrF6Ku4iWD05 Tv84iYZ7R19I/hXaMg+EJlQsZ18KJy13bSLpp5c22l+ffqo8ZvWoImAhm15P3x+dzepg f9xxcHiMb3vtfljSu4Lsh50OQ66jUyc4fVXCzYK4HI2gwepvDRYUErUHRHiICB56K5SX JhVoXEn+i1/KXXmajIjMMzxCq+O5N5MXWHbuS2iTuA2rKvRZ0KpieqwF1a2kli+sAufY 1LoVmXrF+com9vje5jyN6H/9R++nz89kYllIFvJu8C+62nqpMCJtemyrOOHxopVv5EDc BRBg== X-Gm-Message-State: AGi0Pub4pyz1qmOxxyCTO1eJg0nEg88Gt0lbKntNQksqjjrXDA6zLZJ2 TpXYS+xv+2OZPTV6XRKkNXA= X-Google-Smtp-Source: APiQypJsONI1ihWIpiGweun+bJEBnvguPI3pUt809HkMIPsCbAvA1chb0SLvEUm840S8i+v7XnQA8w== X-Received: by 2002:a5d:690a:: with SMTP id t10mr16380554wru.225.1587381015608; Mon, 20 Apr 2020 04:10:15 -0700 (PDT) Received: from localhost (ip-37-188-130-62.eurotel.cz. [37.188.130.62]) by smtp.gmail.com with ESMTPSA id s6sm879443wmh.17.2020.04.20.04.10.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Apr 2020 04:10:14 -0700 (PDT) Date: Mon, 20 Apr 2020 13:10:13 +0200 From: Michal Hocko To: Yafang Shao Cc: Johannes Weiner , Vladimir Davydov , Andrew Morton , Linux MM Subject: Re: [PATCH 3/3] memcg oom: bail out from the charge path if no victim found Message-ID: <20200420111013.GL27314@dhcp22.suse.cz> References: <20200418151311.7397-1-laoar.shao@gmail.com> <20200418151311.7397-4-laoar.shao@gmail.com> <20200420081353.GI27314@dhcp22.suse.cz> <20200420091452.GJ27314@dhcp22.suse.cz> <20200420103142.GK27314@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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 Mon 20-04-20 18:51:50, Yafang Shao wrote: > On Mon, Apr 20, 2020 at 6:31 PM Michal Hocko wrote: [...] > > If this turns out to be infeasible then we should be addressing that > > problem for all possible cases and that means to allow breaking the > > oom_score_adj contract and kill also hidden tasks. > > Breaking the oom_score_adj contract seems another possible way, that > would be accepted by the user - misconfiguration or bugs in user code > should be punished. IOW this is the fault of the user and the kernel > should tell the user the result of this fault. This is not how the kernel behaves in the vast majority of cases. We allow users to shoot their feet. Especially for root only interfaces. We simply rely that admins know what they are doing. So let me repeat there has to be a very strong justification - e.g. it is impossible to remove oom_score_adj OOM killer disabling for some reason and this really happens out there in real deployments. We are surely not going to break the contract based on artificial misconfigured test cases. -- Michal Hocko SUSE Labs