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=-11.6 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_IN_DEF_DKIM_WL 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 8903AC433E0 for ; Mon, 22 Jun 2020 17:13:01 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4A364206E2 for ; Mon, 22 Jun 2020 17:13:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="aEK0cKVi" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4A364206E2 Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id CC5A26B0024; Mon, 22 Jun 2020 13:13:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id C75A26B0025; Mon, 22 Jun 2020 13:13:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B8B016B0026; Mon, 22 Jun 2020 13:13:00 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0121.hostedemail.com [216.40.44.121]) by kanga.kvack.org (Postfix) with ESMTP id 9FD006B0024 for ; Mon, 22 Jun 2020 13:13:00 -0400 (EDT) Received: from smtpin28.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 3061C18083FB2 for ; Mon, 22 Jun 2020 17:13:00 +0000 (UTC) X-FDA: 76957492920.28.smash23_4411a3a26e34 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin28.hostedemail.com (Postfix) with ESMTP id 03A5014240E for ; Mon, 22 Jun 2020 17:12:59 +0000 (UTC) X-HE-Tag: smash23_4411a3a26e34 X-Filterd-Recvd-Size: 4404 Received: from mail-lj1-f194.google.com (mail-lj1-f194.google.com [209.85.208.194]) by imf39.hostedemail.com (Postfix) with ESMTP for ; Mon, 22 Jun 2020 17:12:59 +0000 (UTC) Received: by mail-lj1-f194.google.com with SMTP id y11so20222043ljm.9 for ; Mon, 22 Jun 2020 10:12:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=MczyUKnr4KWUAWPoNy99bqHhQdcxqPt73wnuGURBYbQ=; b=aEK0cKViZ7S0ph9kpZzVfQ8A5ynsiYQa5Ts9xIn8wvCwAjTrINbnY8Byk4x5iPjnzi 0f5U3r+rzHHR+UgvV3vizeA9X+il3u/h+WckB5KVVg0HTFJ6hBT6RQIzbULIczNgw2TG JPGAvh8TP5j0jkbZJhlJ0T1X0+O0QjBCuUNiETb0lo5MRGcIb055JksnVkM2kUmooeqj /3k8TZrUdya8ulEA7Gqc2fiZZ0wyB+IpsmEqOz9/k/qrTX1zaqyhc2QbdlmOipvZ4YQ8 l/8kfFRLCxb4SoYGvY9E4D9vtmEloxBLuTQJ+Xfn+eMPqykXBHVK/GEU95kaavsusBqI ia0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MczyUKnr4KWUAWPoNy99bqHhQdcxqPt73wnuGURBYbQ=; b=bxH8SKvSjIjWRo3b5IMk2GGRr7+DacP10OYhvFh02AhboyRGoIu39949Q8qMWaxA7l RKhJW+3+mC3UMxMllCXnYjus6AVCayVZ4SuTMC6qM5qAt73nzu0GbG9Z8vJ6QH6iX44g 0zF+oPDmOe5n8/ufQHHrC9YXQcECmmCZuWmxLO5uUWQ+spLOzxpXUeMwUmgu7/Tw69Cx KmKyUikQhKy/wAxhpRr1hs0ANdSIIQc7/fQE7PHfgigyqhQPkAlJ1wDjN5iMIGRJGJz6 fO/+8CVMuOsiK+XAFnOykZHumiQ5R9O66GSoh6NkKLUpQNSwRKY2ISMtgFoziDHu7ElU hvpw== X-Gm-Message-State: AOAM533qsyjkinJeFJcmDyQWaUhRrsxdXHY8StNpLxOQ1IPWvh0JwoJx LERF/QFp7SuQgm+vPUW8QPoMqzqJIZ1SwxvW/dQAAQ== X-Google-Smtp-Source: ABdhPJzz/cwMqUCaSL9gP+/s5pE/WjebWsM0Egj2WRCtgz8ZOXxoB5kYkg/zYWM8ANzketpHei1+R4XnkESbxhA0b3g= X-Received: by 2002:a2e:910c:: with SMTP id m12mr9512410ljg.332.1592845977819; Mon, 22 Jun 2020 10:12:57 -0700 (PDT) MIME-Version: 1.0 References: <20200608230654.828134-1-guro@fb.com> <20200608230654.828134-11-guro@fb.com> In-Reply-To: <20200608230654.828134-11-guro@fb.com> From: Shakeel Butt Date: Mon, 22 Jun 2020 10:12:46 -0700 Message-ID: Subject: Re: [PATCH v6 10/19] mm: memcg/slab: deprecate memory.kmem.slabinfo To: Roman Gushchin Cc: Andrew Morton , Christoph Lameter , Johannes Weiner , Michal Hocko , Linux MM , Vlastimil Babka , Kernel Team , LKML Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 03A5014240E X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam05 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, Jun 8, 2020 at 4:07 PM Roman Gushchin wrote: > > Deprecate memory.kmem.slabinfo. > > An empty file will be presented if corresponding config options are > enabled. > > The interface is implementation dependent, isn't present in cgroup v2, > and is generally useful only for core mm debugging purposes. In other > words, it doesn't provide any value for the absolute majority of users. > > A drgn-based replacement can be found in tools/cgroup/slabinfo.py . > It does support cgroup v1 and v2, mimics memory.kmem.slabinfo output > and also allows to get any additional information without a need > to recompile the kernel. > > If a drgn-based solution is too slow for a task, a bpf-based tracing > tool can be used, which can easily keep track of all slab allocations > belonging to a memory cgroup. > > Signed-off-by: Roman Gushchin > Acked-by: Johannes Weiner > Reviewed-by: Vlastimil Babka Hi Roman, I am not against removing the memory.kmem.slabinfo interface but I would like to have an alternative solution more accessible than tools/cgroup/slabinfo.py. In our case, we don't have ssh access and if we need something for debugging, it is much more preferable to provide a file to read to SREs. After the review, that file will be added to a whitelist and then we can directly read that file through automated tools without approval for each request. I am just wondering if a file interface can be provided for whatever tools/cgroup/slabinfo.py is providing. Shakeel