[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALvZod6YaVBqV_LrqgXO13kBS20uoXdm5EGx2CJfBfPC9yj6Cg@mail.gmail.com>
Date: Mon, 26 Jul 2021 23:44:40 -0700
From: Shakeel Butt <shakeelb@...gle.com>
To: Vasily Averin <vvs@...tuozzo.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Cgroups <cgroups@...r.kernel.org>,
Michal Hocko <mhocko@...nel.org>,
Johannes Weiner <hannes@...xchg.org>,
Vladimir Davydov <vdavydov.dev@...il.com>,
Roman Gushchin <guro@...com>,
Alexander Viro <viro@...iv.linux.org.uk>,
linux-fsdevel <linux-fsdevel@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v7 01/10] memcg: enable accounting for mnt_cache entries
On Mon, Jul 26, 2021 at 10:33 PM Vasily Averin <vvs@...tuozzo.com> wrote:
>
> The kernel allocates ~400 bytes of 'strcut mount' for any new mount.
*struct mount*
> Creating a new mount namespace clones most of the parent mounts,
> and this can be repeated many times. Additionally, each mount allocates
> up to PATH_MAX=4096 bytes for mnt->mnt_devname.
>
> It makes sense to account for these allocations to restrict the host's
> memory consumption from inside the memcg-limited container.
>
> Signed-off-by: Vasily Averin <vvs@...tuozzo.com>
Reviewed-by: Shakeel Butt <shakeelb@...gle.com>
Powered by blists - more mailing lists