Page MenuHomeFreeBSD

Various updates to the kernel debugging chapter.
ClosedPublic

Authored by jhb on Mar 16 2018, 8:34 PM.

Details

Summary
  • Document vmcore.last and describe it as the way to find the most recent dump rather than the highest numbered dump.
  • Document crashinfo and that it automatically runs to generate a core.txt.N file if core dumps are enabled in rc.conf.
  • Add a section on testing kernel dumps via the debug.kdb.panic sysctl. Remove a later note about debug.kdb.panic from the DDB section.
  • Remove any mention of gdb -k (for pre 5-3 kernels) and just talk about kgdb.
  • Remove paragraph that talks about trying to find the kernel.debug file. Instead, recommand 'kgdb -n <N>' which does this lookup automatically, and specifically recommend 'kgb -n last' to open the most recent crash dump. Mention the fallback of specifying the kernel and vmcore directly if needed.
  • Remove example dump from FreeBSD 2. It is generally no longer relevant. It used gdb -k which uses a different stack trace format as well as including a 'frame' command that doesn't existing kgdb. (kgdb instead lets you switch to different threads and processes).
  • Remove mention of old boot blocks that don't load debug symbols. I think this was last relevant in FreeBSD 2.x or 3.x.
  • Rework the description of 'boot -d' to assume the boot menu and explicitly mention 'boot -d' at the loader prompt.
  • Document how to get stack traces of other threads in DDB.
  • Fix a few references to gdb to reference kgdb instead.
  • Replace 'call cpu_reset' with 'reset' for DDB.

Diff Detail

Repository
rD FreeBSD doc repository - subversion
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

This revision was not accepted when it landed; it landed in state Needs Review.Apr 18 2018, 11:49 PM
This revision was automatically updated to reflect the committed changes.