From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D6A32C43387 for ; Tue, 18 Dec 2018 08:32:26 +0000 (UTC) Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8B295217D9 for ; Tue, 18 Dec 2018 08:32:26 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="VHkSrNQD" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8B295217D9 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=fail smtp.mailfrom=kernelnewbies-bounces@kernelnewbies.org Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.91) (envelope-from ) id 1gZAnI-0004ls-C6; Tue, 18 Dec 2018 03:32:00 -0500 Received: from mail-ed1-x541.google.com ([2a00:1450:4864:20::541]) by shelob.surriel.com with esmtps (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.91) (envelope-from ) id 1gZAnF-0004lh-9b for kernelnewbies@kernelnewbies.org; Tue, 18 Dec 2018 03:31:57 -0500 Received: by mail-ed1-x541.google.com with SMTP id g22so7071979edr.7 for ; Tue, 18 Dec 2018 00:31:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=gBW2GOcKuAJ5X1r6Men0f5igaV8g7WcxCU3zanFrQ/4=; b=VHkSrNQDlA8pbwHPxDDyZFgfsvqOaYJFueHTAOA4bijizu6BUVusSAcq9iPubPTSS9 oisrYeTNjPCAgpWKuMVmySbcXiZV3McVkL8g+oqnotwKS//kKdTXWbPuOKcDiNTiQjrc h925UlNZrEYU5DMZK2ub5ITs+l12Ax9PCQwiGlOomTAfFlm5dhxHxqn/PXSIgo5khvMe xyZYZ3HtK1ZiEd7BSck1aqNZNThsxQ02HZpTOH7wLO14ipuvOYblowJ6CMs9tej23np+ LllZzA++tckyd/1l+5hOAlcWM5LO2WRqY13IvQ8bgZJIhzn50jPJiZA399HpCJxlAbHE SV4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=gBW2GOcKuAJ5X1r6Men0f5igaV8g7WcxCU3zanFrQ/4=; b=C2HHc6paHqfX7XIGh8+l041h9ZhLPV5/Gif/sMPM/LtIcU+bs0GbiZWMwhgoGBCfzq 5o/Ih2qqK6x9oSy9uehe50qNwxm4DyGaHSzLC8QoWRhhTtjwVsG3lrYyaWQ+KTuE46iU 8M68joBzy0zX2wsnxzRatiS4BxwxUQEIauzKrYxKLg/ICMMjtL1a5xRWlicmLUL5CDR8 ZaTbgn7P49lR/Yz9CSl3ltqIh368VteMQZ81IpX3hZXYB48vVy5VLJAEOiyiEKwfZGCB YiKyW5c8QVPgTcJ7PqnooGra5ozJSdlITCmVoNWJ5N52OWdXVypjtGDccEtTXmrEJygA x9Fw== X-Gm-Message-State: AA+aEWb3MFQjqVbc4Mk2+wwdw8h0WueXSZSKTzAQ3VKlSBMMN0Nlq14z m0kr04huMHUqSqh64FaPYwi5rck2u/ezcOESVsJx2FHku1Q= X-Google-Smtp-Source: AFSGD/WT6NdzZ5yyePvf+AIqvZTMZ4nrWEjqJPI/vNeQqJVBIjuxpMZ80G+w/MNED3/heyF9ZtCGl7ItL9m70zJAOqA= X-Received: by 2002:a50:ef18:: with SMTP id m24mr15559372eds.136.1545121914670; Tue, 18 Dec 2018 00:31:54 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Harsh Jain Date: Tue, 18 Dec 2018 14:01:42 +0530 Message-ID: Subject: Re: How to detect slab memory leak To: Mulyadi Santosa Cc: Naruto Nguyen , kernelnewbies X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernelnewbies-bounces@kernelnewbies.org You can try kernel config option "CONFIG_DEBUG_KMEMLEAK". https://www.kernel.org/doc/html/v4.10/dev-tools/kmemleak.html On Tue, Dec 18, 2018 at 1:14 PM Mulyadi Santosa wrote: > > > > On Sun, Dec 16, 2018 at 1:25 PM Naruto Nguyen wrote: >> >> Hi everyone, >> >> When using slabtop to display the cache size growing, I see that >> kmalloc-1024 and kmalloc-256 are increasing about 200MB after 1 hour. >> Is there any way to detect which kernel components cause this slab >> increase? >> >> Thanks a lot, >> Brs, >> Naruto >> > > Hello Naruto > > I think you can do it by instrumenting call to kmalloc(). These days, eBPF is the hot stuff to try for this matter. See if it fits yours too. > > regards, > > Mulyadi > >> >> _______________________________________________ >> Kernelnewbies mailing list >> Kernelnewbies@kernelnewbies.org >> https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies > > > > -- > regards, > > Mulyadi Santosa > Freelance Linux trainer and consultant > > blog: the-hydra.blogspot.com > training: mulyaditraining.blogspot.com > _______________________________________________ > Kernelnewbies mailing list > Kernelnewbies@kernelnewbies.org > https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies