From: bugzilla-daemon@bugzilla.kernel.org
To: linux-ext4@vger.kernel.org
Subject: [Bug 108631] Stuck on mb_cache_spinlock
Date: Thu, 07 Jan 2016 15:49:40 +0000 [thread overview]
Message-ID: <bug-108631-13602-wkkdU1bCEc@https.bugzilla.kernel.org/> (raw)
In-Reply-To: <bug-108631-13602@https.bugzilla.kernel.org/>
https://bugzilla.kernel.org/show_bug.cgi?id=108631
--- Comment #6 from Theodore Tso <tytso@mit.edu> ---
You said that you had replicated this problem on 4.2, so it's probably not the
primary driver of the problem in your case, but be aware that in some of the
older kernels (and 3.14 is included in that list), the shrinker is not cgroup
aware. That means that if a single container starts aggressively using all of
its memory, we will start kicking off *all* of the slab cache shrinkers. I've
seen that in a very container-heavy environment, with many tasks that use right
up to their memory cgroup limit (and sometimes beyond), that this can cause the
ext4 extent status cache shrinker to end up getting run a lot, which leads to
symptoms similar to yours due to spinlock contention. (Of course, for a
different spinlock since a different slab cache shrinker is involved).
I've been playing with some patches to use trylock and to abandon the ext4 es
shrinker if it's under too much lock contention, but I haven't come up with
something for which I was sufficiently happy to push upstream yet --- because
if the slab cache does need shrinker, just simply giving up isn't going to do
the right thing entirely, either.
One hacky solution would be to add knobs so we can cap the size of various
caches like the mbcache and extents status cache so we can afford to be more
aggressive at giving up if the trylock fails. But assuming that system
administrators will *set* these knobs correctly is probably a bad choice. So
this is a more general problem than just the mbcache, and I haven't found a
good general solution yet. And there may not be; we can try to make systems
that are less likely to lead to spinlock contention, but under sufficiently
heavy memory pressure, this may only be forestalling the inevitable.
--
You are receiving this mail because:
You are watching the assignee of the bug.
next prev parent reply other threads:[~2016-01-07 15:49 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-30 16:36 [Bug 108631] New: Stuck on mb_cache_spinlock bugzilla-daemon
2016-01-07 9:02 ` [Bug 108631] " bugzilla-daemon
2016-01-07 14:09 ` bugzilla-daemon
2016-01-07 14:10 ` bugzilla-daemon
2016-01-07 15:06 ` bugzilla-daemon
2016-01-07 15:33 ` bugzilla-daemon
2016-01-07 15:49 ` bugzilla-daemon [this message]
2016-01-22 9:08 ` bugzilla-daemon
2016-03-20 21:54 ` bugzilla-daemon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-108631-13602-wkkdU1bCEc@https.bugzilla.kernel.org/ \
--to=bugzilla-daemon@bugzilla.kernel.org \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).