NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: install/46355: Should INSTALL kernels drop to DDB on panic?

The following reply was made to PR install/46355; it has been noted by GNATS.

From: Martin Husemann <>
Subject: Re: install/46355: Should INSTALL kernels drop to DDB on panic?
Date: Thu, 19 Apr 2012 09:49:49 +0200

 On Thu, Apr 19, 2012 at 05:55:00AM +0000, Matthew Mondor wrote:
 > I noticed that the INSTALL kernel includes the GENERIC config file,
 > which defaults to dump core on panic.  Thus, INSTALL will attempt to
 > drop core instead of entering DDB if it panics at boot.
 No, it will not, but let's make a short detour:
 The original plan was: make the kernel drop to ddb by default, but then,
 once /etc/rc runs and we have a working disk, switch to "dump core".
 See /etc/sysctl.conf:
 # Default on panic: dump core and reboot. See savecore(8) for information.
 # Switch this to 1 if you want to enter the kernel debugger on crashes
 # instead. See ddb(4) for an introduction and also try the "help" command
 # at the db> prompt.
 # If you understand the implication and want to change the behaviour before
 # /etc/rc.d/sysctl is run, use the kernel option DDB_ONPANIC, see options(4).
 So short summary: all GENERIC/MODULAR kernels should effectively have
 DDB_ONPANIC=1 (or 2) as default, but 1 is the default if the option is
 missing (see src/sys/ddb/db_variables.c). It seems that the kernels we
 use for install do not have the option, so everything should be fine.
 If you see an instant reboot instead of ddb somewhere after a panic,
 something else is wrong.

Home | Main Index | Thread Index | Old Index