Kernel debugger

Debugger for kernel development


title: "Kernel debugger" type: doc version: 1 created: 2026-02-28 author: "Wikipedia contributors" status: active scope: public tags: ["debuggers", "operating-system-kernels"] description: "Debugger for kernel development" topic_path: "general/debuggers" source: "https://en.wikipedia.org/wiki/Kernel_debugger" license: "CC BY-SA 4.0" wikipedia_page_id: 0 wikipedia_revision_id: 0

::summary Debugger for kernel development ::

A kernel debugger is a debugger present in some operating system kernels to ease debugging and kernel development by the kernel developers. A kernel debugger might be a stub implementing low-level operations, with a full-blown debugger such as GNU Debugger (gdb), running on another machine, sending commands to the stub over a serial line or a network connection, or it might provide a command line that can be used directly on the machine being debugged.

Operating systems and operating system kernels that contain a kernel debugger:

  • The Windows NT family includes a kernel debugger named KD, which can act as a local debugger with limited capabilities (reading and writing kernel memory, and setting breakpoints) and can attach to a remote machine over a serial line, IEEE 1394 connection, USB 2.0 or USB 3.0 connection. The WinDbg GUI debugger can also be used to debug kernels on local and remote machines.
  • BeOS and Haiku include a kernel debugger usable with either an on-screen console or over a serial line. It features various commands to inspect memory, threads, and other kernel structures. In Haiku, the debugger is called "Kernel Debugging Land" (KDL).
  • DragonFly BSD
  • Linux kernel; No kernel debugger was included in the mainline Linux tree prior to version 2.6.26-rc1 because Linus Torvalds didn't want a kernel debugger in the kernel.
    • KDB (local)
    • KGDB (remote)
    • MDB (local/remote)
  • NetBSD has DDB for local and KGDB for remote.
  • macOS has ddb for local and kdp for remote.
  • OpenBSD includes ddb which has a syntax is similar to GNU Debugger.

References

References

  1. "Debugging Environments". Debugging Tools for Windows (WinDbg, KD, CDB, NTSD).
  2. "Local Kernel-Mode Debugging".
  3. "Live Kernel-Mode Debugging Using KD".
  4. "Welcome to Kernel Debugging Land".
  5. "LWN.net".
  6. Torvalds, Linus. (3 May 2008). "Linux 2.6.26-rc1". LWN.
  7. Nellitheertha, Hariprasad. "Inside the Linux kernel debugger".
  8. (7 Sep 2008). "LWN Weekly Kernel News".
  9. (1 Jan 2016). "MDB Github Website".
  10. (28 June 2010). "LWN Weekly Kernel News".
  11. Singh, Amit. (December 2003). "XNU: The Kernel". What is Mac OS X?.
  12. . (2019-12-06). ["ddb(4)"](https://man.openbsd.org/ddb).

::callout[type=info title="Wikipedia Source"] This article was imported from Wikipedia and is available under the Creative Commons Attribution-ShareAlike 4.0 License. Content has been adapted to SurfDoc format. Original contributors can be found on the article history page. ::

debuggersoperating-system-kernels