lkml.org 
[lkml]   [2022]   [Aug]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 0/3] enable memcg accounting for kernfs objects
(cc'ing Johannes)

Hello,

On Sun, Jul 31, 2022 at 06:37:15PM +0300, Vasily Averin wrote:
> 1) creating a new netdevice allocates ~50Kb of memory, where ~10Kb
> was allocated for 80+ kernfs nodes.
>
> 2) cgroupv2 mkdir allocates ~60Kb of memory, ~10Kb of them are kernfs
> structures.
>
> 3) Shakeel Butt reports that Google has workloads which create 100s
> of subcontainers and they have observed high system overhead
> without memcg accounting of kernfs.

So, I don't have anything against accounting kernfs objects in general but,
for cgroups, because cgroups are what determines what gets charged where,
I'm not quite sure whether following the usual "charge it to the allocating
task's cgroup" is the best way to go about it. I wonder whether it'd be
better to attach it to the new cgroup's nearest ancestor with memcg enabled.
Johannes, Michal, what do you guys think?

Thanks.

--
tejun

\
 
 \ /
  Last update: 2022-08-09 19:32    [W:0.300 / U:1.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site