From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751585AbdG0Ri7 convert rfc822-to-8bit (ORCPT ); Thu, 27 Jul 2017 13:38:59 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44038 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751441AbdG0Ri5 (ORCPT ); Thu, 27 Jul 2017 13:38:57 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 1C0D4C073D69 Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=longman@redhat.com Subject: Re: [PATCH] cgroup: add cgroup.stat interface with basic hierarchy stats To: Roman Gushchin , cgroups@vger.kernel.org Cc: Tejun Heo , Zefan Li , Johannes Weiner , kernel-team@fb.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170727161420.2552-1-guro@fb.com> From: Waiman Long Organization: Red Hat Message-ID: <6a72e074-e01f-b93f-2c03-2bd0366d005b@redhat.com> Date: Thu, 27 Jul 2017 13:38:55 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 MIME-Version: 1.0 In-Reply-To: <20170727161420.2552-1-guro@fb.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8BIT Content-Language: en-US X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 27 Jul 2017 17:38:57 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/27/2017 12:14 PM, Roman Gushchin wrote: > Add a cgroup.stat interface to the base cgroup control files > with the following metrics: > > nr_descendants total number of descendant cgroups > nr_dying_descendants total number of dying descendant cgroups > max_descendant_depth maximum descent depth below the current cgroup Both nr_descendants and max_descendant_depth can be found easily from userspace by scanning the cgroup directory. nr_dying_descendants is a transient figure and it should be 0 most of the time. So I wonder how useful it can be. This new interface file will be more useful if it can reveal information that cannot be easily obtained by looking from userspace alone. Cheers, Longman