Update the kernel debugging FAQ to match the new (k)gdb and new DDB

symbol behaviour.
This commit is contained in:
Joerg Wunsch 1995-03-25 12:35:00 +00:00
parent a7d783dddb
commit d92d2e1236
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=7355

View File

@ -1,10 +1,15 @@
Kernel debugging FAQ for FreeBSD
$Id: kernel-debug.FAQ,v 1.4 1995/01/03 15:54:03 gclarkii Exp $
$Id: kernel-debug.FAQ,v 1.1 1995/03/21 20:19:31 jkh Exp $
*** Debugging a kernel crash dump with kgdb ***
[In the following, the term ``kgdb'' refers to gdb run in `kernel
debug mode'. This can be accomplished by either starting the gdb
with the option ``-k'', or by linking and starting it under the
name ``kgdb''. This is not being done by default, however.]
Here are some instructions for getting kernel debugging working on a
crash dump, it assumes that you have enough swap space for a crash
dump. If you happen to have multiple swap partitions with the first
@ -226,32 +231,15 @@ $Id: kernel-debug.FAQ,v 1.4 1995/01/03 15:54:03 gclarkii Exp $
full debug information (including type and line number information)
like kgdb.
To configure your kernel to include DDB, add the option lines
To configure your kernel to include DDB, add the option line
options DDB
options "SYMTAB_SPACE=XXXX"
to your config file, and rebuild. XXXX is the amount of space to be
reserved into a global array DDB examines to find its symbols at run
time. It must be large enough to hold all symbols, but not too
large at all to avoid wasting space. 100000 Bytes are a good first
bet for a ``normal'' kernel. The link stage will tell you about the
usage of the symtab space, you'll see something like:
dbsym: need 98765; avail 100000
If the amount of allocated space has been too small, the above
message is accompanied by the following error message:
not enough room in db_symtab array
and the link stage fails. You then need to increase the number,
reconfig and recompile. If your config(8) has been compiled to not
remove the old compile directory before continuing (this is a
compile-time option [CONFIG_DONT_CLOBBER]), you need to remove
db_aout.o prior to recompilation; this is the only file being
affected by the SYMTAB_SPACE option.
to your config file, and rebuild.
(Note that if you have an older version of the boot blocks, your
debugger symbols might not be loaded at all. Update the boot
blocks, the recent ones do load the DDB symbols automagically.)
Once your DDB kernel is running, there are several ways to enter
DDB. The first (and most early) way is to set the boot flag `-d'
@ -386,6 +374,8 @@ $Id: kernel-debug.FAQ,v 1.4 1995/01/03 15:54:03 gclarkii Exp $
will cause your kernel to dump core and reboot, so you can later
analyze the core on a higher level with kgdb.
There's now an alias for this: ``panic''.
call boot(0)