SHARE
Facebook X Pinterest WhatsApp

Detecting memory leaks & invalid memory de-allocation in the Linux kernel

Written By
thumbnail
Web Webster
Web Webster
May 18, 2009

Embedded.com pulled the article, sorry! –ed.

“In user space there are many open source projects that one can
use to identify memory leaks and corruptions such as electric fence
[6], its newer fork DUMA [7], and valgrind [8]. However, for code
running in kernel context these tools are not available.

“When the problems mentioned above end up as a “kernel panic” as
they often do, there is no further ability for the engineer to
inspect the offending code other than to observe the stack trace.
Also in kernel context, a memory leak is persistent: it will remain
existent and most probably keep growing until a reboot, something
that is unacceptable.

“Kernel development allows direct access to the basic components
and resources of the operating system, but debugging is not easy as
the use of a debugger is not handy. One has to either use
additional logging or use advanced techniques such as using kernel
debuggers like kdb [2][3] and kgdb [4] or use kernel patches such
as the one provided by Catalin Marinas, described in [1].”

Complete
Story

thumbnail
Web Webster

Web Webster

Web Webster has more than 20 years of writing and editorial experience in the tech sector. He’s written and edited news, demand generation, user-focused, and thought leadership content for business software solutions, consumer tech, and Linux Today, he edits and writes for a portfolio of tech industry news and analysis websites including webopedia.com, and DatabaseJournal.com.

Recommended for you...

5 Best Free and Open Source Text Expander Tools
webmaster
Jun 13, 2025
Grafito: Systemd Journal Log Viewer with a Beautiful Web UI
Bobby Borisov
Jun 12, 2025
FreeBSD Wants to Know a Few Things
brideoflinux
May 11, 2025
NVK enabled for Maxwell, Pascal, and Volta GPUs
Kara Bembridge
May 1, 2025
Linux Today Logo

LinuxToday is a trusted, contributor-driven news resource supporting all types of Linux users. Our thriving international community engages with us through social media and frequent content contributions aimed at solving problems ranging from personal computing to enterprise-level IT operations. LinuxToday serves as a home for a community that struggles to find comparable information elsewhere on the web.

Property of TechnologyAdvice. © 2025 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.