[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20180219143343.u5ckigir7svpkiem@quack2.suse.cz>
Date: Mon, 19 Feb 2018 15:33:43 +0100
From: Jan Kara <jack@...e.cz>
To: Amir Goldstein <amir73il@...il.com>
Cc: Shakeel Butt <shakeelb@...gle.com>, Jan Kara <jack@...e.cz>,
Christoph Lameter <cl@...ux.com>,
Pekka Enberg <penberg@...nel.org>,
David Rientjes <rientjes@...gle.com>,
Joonsoo Kim <iamjoonsoo.kim@....com>,
Andrew Morton <akpm@...ux-foundation.org>,
Greg Thelen <gthelen@...gle.com>,
Johannes Weiner <hannes@...xchg.org>,
Michal Hocko <mhocko@...nel.org>,
Vladimir Davydov <vdavydov.dev@...il.com>,
Mel Gorman <mgorman@...e.de>, Vlastimil Babka <vbabka@...e.cz>,
linux-fsdevel <linux-fsdevel@...r.kernel.org>,
Linux MM <linux-mm@...ck.org>, cgroups@...r.kernel.org,
linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH 3/3] fs: fsnotify: account fsnotify metadata to kmemcg
On Wed 14-02-18 10:08:31, Amir Goldstein wrote:
> On Wed, Feb 14, 2018 at 4:56 AM, Shakeel Butt <shakeelb@...gle.com> wrote:
> > This is RFC patch and the discussion on the API is still happening at
> > the following link but I am sending the early draft for feedback.
> > [link] https://marc.info/?l=linux-api&m=151850343717274
> >
> > A lot of memory can be consumed by the events generated for the huge or
> > unlimited queues if there is either no or slow listener. This can cause
> > system level memory pressure or OOMs. So, it's better to account the
> > fsnotify kmem caches to the memcg of the listener.
> >
> > There are seven fsnotify kmem caches and among them allocations from
> > dnotify_struct_cache, dnotify_mark_cache, fanotify_mark_cache and
> > inotify_inode_mark_cachep happens in the context of syscall from the
>
> fsnotify_mark_connector_cachep as well.
Yes, but for the purposes of memcg accounting, I'd just ignore this cache
and not account fsnotify_mark_connector objects at all. They are small
compared to the notification mark or events and it is unclear whom to
account connector to since it is shared by all events attached to the
inode.
Honza
--
Jan Kara <jack@...e.com>
SUSE Labs, CR
Powered by blists - more mailing lists