From patchwork Fri Feb 26 02:12:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Shi X-Patchwork-Id: 12105661 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=-13.5 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham 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 05F7AC433DB for ; Fri, 26 Feb 2021 02:13:00 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 68A2564EF5 for ; Fri, 26 Feb 2021 02:12:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 68A2564EF5 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id DD0116B0005; Thu, 25 Feb 2021 21:12:58 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D7F026B0006; Thu, 25 Feb 2021 21:12:58 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C949C6B006C; Thu, 25 Feb 2021 21:12:58 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0042.hostedemail.com [216.40.44.42]) by kanga.kvack.org (Postfix) with ESMTP id B39AA6B0005 for ; Thu, 25 Feb 2021 21:12:58 -0500 (EST) Received: from smtpin10.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 810351801E207 for ; Fri, 26 Feb 2021 02:12:58 +0000 (UTC) X-FDA: 77858796036.10.0FDD0FE Received: from mail-pf1-f181.google.com (mail-pf1-f181.google.com [209.85.210.181]) by imf04.hostedemail.com (Postfix) with ESMTP id A513BD7 for ; Fri, 26 Feb 2021 02:12:56 +0000 (UTC) Received: by mail-pf1-f181.google.com with SMTP id r5so5194638pfh.13 for ; Thu, 25 Feb 2021 18:12:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=yeWyaSel7U9eSxOcBt5qJfEQetEzs7vQl7xINbGhi+A=; b=XY79rE3hGyDbLdFZT8nD2HQ1isKgQ+OFXiOIFTeR5H5a4FsQVMdFmsvacNlq6pS2lJ 6GEHyvu4EenSb95Z985YMZlDcrT9jFr5k6UHhpDX1lTCfy55JW/r0VBqmhCPvs9QvsJS ue0OTjy5vzxt+HAv6Ly+dnAPPjSa+gWpta1e+bGZWtR+GLbTwd+O7w+vE78ZDdO5bYEh vCjFC9c1jP7tyIDYo3u85cqKvMwxnDB4w2K7tS5cV90u4kr6WLzbKDwWTnMcJlrRHxTF h5CM+3Nl9E/dvsPEhZTwffOc2UEJLB/UWrfQuDj5xWjKqKaW9RpZ6L2myBIXiB4XIvD6 MPaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=yeWyaSel7U9eSxOcBt5qJfEQetEzs7vQl7xINbGhi+A=; b=S+dp1d19y/fvi8+afwPhpNBnSdU/NVIZDpQV0jlziwKXtpyGxzjnO4BqxYHzlD3Cp1 MPMqjvce3H4R3sXPmUZDmo1fXNu3NfOu9PUUIb/ZODEC47kPkLF/U8ghDZBRCZeQEii8 dUD20cBxRnR0Kgvmmk+q85LDuP+LjokJEQKqTmCYyC4IIET+We8OHIXC3dz0yDNUWRxE TcZkRyetCmdy48L7leeMlsR/gT4yWsqSpLV1DoQlkg+6czwhlu1RSNaAqs2zzSKStXSR nKtyaYo1mtESxCrw7PyTzIuAuxRMSqmsWtsipJwAMiquhWgaG29cmYhtDw4/nAu+grQv y3tQ== X-Gm-Message-State: AOAM532Pk+sKSdaNdBROXtFYCxmaHvDWP0ZXI1bav7NxoDjP90yf4QQQ LRa68gCCSuM1tugPHx6pkyY= X-Google-Smtp-Source: ABdhPJw2+rDNi4gbjIsJUVGbsD6lPhwC1Ye+NPiIPMpls61+YQ/vGQj+DCb4ukpnWdAi4yyH7OokWg== X-Received: by 2002:aa7:8f15:0:b029:1ed:9356:a9e with SMTP id x21-20020aa78f150000b02901ed93560a9emr691428pfr.73.1614305576840; Thu, 25 Feb 2021 18:12:56 -0800 (PST) Received: from localhost.localdomain (c-73-93-239-127.hsd1.ca.comcast.net. [73.93.239.127]) by smtp.gmail.com with ESMTPSA id 8sm7773531pfp.171.2021.02.25.18.12.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Feb 2021 18:12:56 -0800 (PST) From: Yang Shi To: hannes@cmpxchg.org, mhocko@suse.com, guro@fb.com, shakeelb@google.com, akpm@linux-foundation.org, corbet@lwn.net Cc: shy828301@gmail.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH] doc: memcontrol: add description for oom_kill Date: Thu, 25 Feb 2021 18:12:54 -0800 Message-Id: <20210226021254.3980-1-shy828301@gmail.com> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 X-Stat-Signature: kjpm3y3tzu554quejkhr6rpan3bqa38m X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: A513BD7 Received-SPF: none (gmail.com>: No applicable sender policy available) receiver=imf04; identity=mailfrom; envelope-from=""; helo=mail-pf1-f181.google.com; client-ip=209.85.210.181 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1614305576-153452 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: When debugging an oom issue, I found the oom_kill counter of memcg is confusing. At the first glance without checking document, I thought it just counts for memcg oom, but it turns out it counts both global and memcg oom. The cgroup v2 documents it, but the description is missed for cgroup v1. Signed-off-by: Yang Shi Acked-by: Michal Hocko Reviewed-by: Shakeel Butt Acked-by: Chris Down --- Documentation/admin-guide/cgroup-v1/memory.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/admin-guide/cgroup-v1/memory.rst b/Documentation/admin-guide/cgroup-v1/memory.rst index 0936412e044e..44d5429636e2 100644 --- a/Documentation/admin-guide/cgroup-v1/memory.rst +++ b/Documentation/admin-guide/cgroup-v1/memory.rst @@ -851,6 +851,9 @@ At reading, current status of OOM is shown. (if 1, oom-killer is disabled) - under_oom 0 or 1 (if 1, the memory cgroup is under OOM, tasks may be stopped.) + - oom_kill integer counter + The number of processes belonging to this cgroup killed by any + kind of OOM killer. 11. Memory Pressure ===================