Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

Udemy

Debugging Linux Kernel in Deep - Part 2

via Udemy

Overview

KGDB, KDB, GDB

What you'll learn:
  • Debugging Linux Kernel Using KGDB
  • KGDB on Raspberry Pi3

User space processes can be debugged using gdb. With gdb you can

  • single-step,

  • stop,

  • resume,

  • put break-points,

  • inspect memory and variables,

  • look through call stack information

What if we can use gdb on running Linux Kernel.

Problem:

How can a gdb debug running kernel as it is just a user space process.

Solution:

Client/Server Architecture

User space programs can be debugged remotely using the combination of gdbserver on the target machine and gdb on the host machine/development machine.

The Linux kernel has a GDB Server implementation called KGDB. It communicates with a GDB client over network or serial port connection

In this course we will learn:

  • How to setup KGDB

  • Various ways of getting the target into development machine

  • Setting Breakpoints

  • Printing and Setting Variables

  • Using a single serial port for both kgdb and console messages

  • Getting the kernel messages in gdb window

  • Debugging Linux Kernel Modules (In-Tree, out of tree)

  • Use of GDB Scripts present in the Linux Kernel

Syllabus

  • Introduction to KGDB
  • Advanced Kgdb
  • KGDB on Raspberry Pi3
  • Downloads

Taught by

Linux Trainer

Reviews

4.5 rating at Udemy based on 131 ratings

Start your review of Debugging Linux Kernel in Deep - Part 2

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.