Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-10-02 Thread Yang Shi
On 10/2/17 12:26 AM, Michal Hocko wrote: On Thu 28-09-17 01:25:50, Yang Shi wrote: On 9/27/17 3:45 AM, Michal Hocko wrote: On Wed 27-09-17 08:53:35, Yang Shi wrote: Kernel may panic when oom happens without killable process sometimes it is caused by huge unreclaimable slabs used by kernel.

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-10-02 Thread Yang Shi
On 9/30/17 11:43 PM, Christopher Lameter wrote: On Thu, 28 Sep 2017, Yang Shi wrote: CONFIG_SLABINFO and /proc/slabinfo have nothing to do with the unreclaimable slab info. The current design uses "struct slabinfo" and get_slabinfo() to retrieve some info, i.e. active objs, etc. They are pr

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-10-02 Thread Michal Hocko
On Thu 28-09-17 01:25:50, Yang Shi wrote: > > > On 9/27/17 3:45 AM, Michal Hocko wrote: > > On Wed 27-09-17 08:53:35, Yang Shi wrote: > > > Kernel may panic when oom happens without killable process sometimes it > > > is caused by huge unreclaimable slabs used by kernel. > > > > > > Although kdu

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-30 Thread Christopher Lameter
On Thu, 28 Sep 2017, Yang Shi wrote: > > CONFIG_SLABINFO and /proc/slabinfo have nothing to do with the > > unreclaimable slab info. > > The current design uses "struct slabinfo" and get_slabinfo() to retrieve some > info, i.e. active objs, etc. They are protected by CONFIG_SLABINFO. Ok I guess t

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Yang Shi
On 9/27/17 2:59 PM, Christopher Lameter wrote: On Thu, 28 Sep 2017, Yang Shi wrote: CONFIG_SLABINFO? How does this relate to the oom info? /proc/slabinfo support is optional. Oom info could be included even if CONFIG_SLABINFO goes away. Remove the #ifdef? Because we want to dump the unreclai

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Christopher Lameter
On Thu, 28 Sep 2017, Yang Shi wrote: > > CONFIG_SLABINFO? How does this relate to the oom info? /proc/slabinfo > > support is optional. Oom info could be included even if CONFIG_SLABINFO > > goes away. Remove the #ifdef? > > Because we want to dump the unreclaimable slab info in oom info. CONFIG_S

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Yang Shi
On 9/27/17 3:45 AM, Michal Hocko wrote: On Wed 27-09-17 08:53:35, Yang Shi wrote: Kernel may panic when oom happens without killable process sometimes it is caused by huge unreclaimable slabs used by kernel. Although kdump could help debug such problem, however, kdump is not available on all

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Yang Shi
On 9/27/17 12:14 AM, Christopher Lameter wrote: On Wed, 27 Sep 2017, Yang Shi wrote: Print out unreclaimable slab info (used size and total size) which actual memory usage is not zero (num_objs * size != 0) when: - unreclaimable slabs : all user memory > unreclaim_slabs_oom_ratio - pani

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Michal Hocko
On Wed 27-09-17 08:53:35, Yang Shi wrote: > Kernel may panic when oom happens without killable process sometimes it > is caused by huge unreclaimable slabs used by kernel. > > Although kdump could help debug such problem, however, kdump is not > available on all architectures and it might be malfu

Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-27 Thread Christopher Lameter
On Wed, 27 Sep 2017, Yang Shi wrote: > Print out unreclaimable slab info (used size and total size) which > actual memory usage is not zero (num_objs * size != 0) when: > - unreclaimable slabs : all user memory > unreclaim_slabs_oom_ratio > - panic_on_oom is set or no killable process Ok. I l

[PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic

2017-09-26 Thread Yang Shi
Kernel may panic when oom happens without killable process sometimes it is caused by huge unreclaimable slabs used by kernel. Although kdump could help debug such problem, however, kdump is not available on all architectures and it might be malfunction sometime. And, since kernel already panic it