* memcg/kmem panics
@ 2019-06-19 22:50 Dave Hansen
2019-06-19 23:04 ` Shakeel Butt
0 siblings, 1 reply; 2+ messages in thread
From: Dave Hansen @ 2019-06-19 22:50 UTC (permalink / raw)
To: Johannes Weiner, Michal Hocko, Vladimir Davydov, cgroups,
linux-mm, LKML, Williams, Dan J
I have a bit of a grievance to file. :)
I'm seeing "Cannot create slab..." panic()s coming from
kmem_cache_open() when trying to create memory cgroups on a Fedora
system running 5.2-rc's. The panic()s happen when failing to create
memcg-specific slabs because the memcg code passes through the
root_cache->flags, which can include SLAB_PANIC.
I haven't tracked down the root cause yet, or where this behavior
started. But, the end-user experience is that systemd tries to create a
cgroup and ends up with a kernel panic. That's rather sad, especially
for the poor sod that's trying to debug it.
Should memcg_create_kmem_cache() be, perhaps filtering out SLAB_PANIC
from root_cache->flags, for instance? That might make the system a bit
less likely to turn into a doorstop if and when something goes mildly
wrong. I've hacked out the panic()s and the system actually seems to
boot OK.
BTW, this particular system has some persistent memory in it. I suspect
there's something wrong where the slab code is trying to create slabs
for pmem-only nodes. But,
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: memcg/kmem panics
2019-06-19 22:50 memcg/kmem panics Dave Hansen
@ 2019-06-19 23:04 ` Shakeel Butt
0 siblings, 0 replies; 2+ messages in thread
From: Shakeel Butt @ 2019-06-19 23:04 UTC (permalink / raw)
To: Dave Hansen
Cc: Johannes Weiner, Michal Hocko, Vladimir Davydov, Cgroups,
Linux MM, LKML, Williams, Dan J
On Wed, Jun 19, 2019 at 3:50 PM Dave Hansen <dave.hansen@intel.com> wrote:
>
> I have a bit of a grievance to file. :)
>
> I'm seeing "Cannot create slab..." panic()s coming from
> kmem_cache_open() when trying to create memory cgroups on a Fedora
> system running 5.2-rc's. The panic()s happen when failing to create
> memcg-specific slabs because the memcg code passes through the
> root_cache->flags, which can include SLAB_PANIC.
>
> I haven't tracked down the root cause yet, or where this behavior
> started. But, the end-user experience is that systemd tries to create a
> cgroup and ends up with a kernel panic. That's rather sad, especially
> for the poor sod that's trying to debug it.
>
> Should memcg_create_kmem_cache() be, perhaps filtering out SLAB_PANIC
> from root_cache->flags, for instance? That might make the system a bit
> less likely to turn into a doorstop if and when something goes mildly
> wrong. I've hacked out the panic()s and the system actually seems to
> boot OK.
You must be using CONFIG_SLUB and I see that in kmem_cache_open() in
SLUB doing a SLAB_PANIC check. I think we should remove that
altogether from SLUB as SLAB does not do this and failure in memcg
kmem cache creation can and should be handled gracefully. I can send a
patch to remove that check.
Shakeel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-06-19 23:04 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-19 22:50 memcg/kmem panics Dave Hansen
2019-06-19 23:04 ` Shakeel Butt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox