From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750986AbdJBH0L (ORCPT ); Mon, 2 Oct 2017 03:26:11 -0400 Received: from mx2.suse.de ([195.135.220.15]:57562 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750760AbdJBH0K (ORCPT ); Mon, 2 Oct 2017 03:26:10 -0400 Date: Mon, 2 Oct 2017 09:26:07 +0200 From: Michal Hocko To: Yang Shi Cc: cl@linux.com, penberg@kernel.org, rientjes@google.com, iamjoonsoo.kim@lge.com, akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/3] mm: oom: show unreclaimable slab info when kernel panic Message-ID: <20171002072607.sjikpsoaiyebmukd@dhcp22.suse.cz> References: <1506473616-88120-1-git-send-email-yang.s@alibaba-inc.com> <1506473616-88120-3-git-send-email-yang.s@alibaba-inc.com> <20170927104537.r42javxhnyqlxnqm@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 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 is worthy capturing such information > > > in dmesg to aid touble shooting. > > > > > > 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, this is better but I do not see why this should be tunable via proc. > > Just thought someone might want to dump unreclaimable slab info > unconditionally. If that ever happens then we will eventually add it. But do not add proc knobs for theoretical usecases. We will have to maintain them and it can turn into a maint. pain. Like some others in the past. -- Michal Hocko SUSE Labs