Discussion:
how to set dumpdev
Danny Braniss
2005-04-28 08:19:47 UTC
Permalink
hi,
i can't use dumpon, since the kernel is panicking on boot, so
tried in loader.conf:
dumpdev="/dev/ar0s1b"
but getting:
db> call doadump
Cannot dump. No dump device defined.
0x25

i need this is for current 6.0
thanks,
danny
Andre Guibert de Bruet
2005-04-28 09:37:16 UTC
Permalink
Post by Danny Braniss
i can't use dumpon, since the kernel is panicking on boot, so
dumpdev="/dev/ar0s1b"
db> call doadump
Cannot dump. No dump device defined.
0x25
i need this is for current 6.0
thanks,
danny
That directive, along with dumpdir, would be set in /etc/rc.conf.

Andy

| Andre Guibert de Bruet | Enterprise Software Consultant >
| Silicon Landmark, LLC. | http://siliconlandmark.com/ >
Thierry Herbelot
2005-04-28 10:09:44 UTC
Permalink
Post by Danny Braniss
i can't use dumpon, since the kernel is panicking on boot, so
Hello,

There used to be a "dump" directive in the kernel config file (config root on
XXX swap on YYY dump on ZZZ), but I can't find any trace in our kernel or in
current config file of NetBSD or OpenBSD (time to resurrect the option ?).

In your case, this kind of hardwired configuration knob would certainly be
handy (I've looked at the code in dumpon.c : the dump device is selected via
an IOCTL and not a loader-tunable sysctl flag : too bad).

TfH
Brian Candler
2005-04-28 10:29:36 UTC
Permalink
Post by Andre Guibert de Bruet
Post by Danny Braniss
i can't use dumpon, since the kernel is panicking on boot, so
dumpdev="/dev/ar0s1b"
db> call doadump
Cannot dump. No dump device defined.
0x25
i need this is for current 6.0
thanks,
danny
That directive, along with dumpdir, would be set in /etc/rc.conf.
According to `man dumpon` (on a 5-STABLE system):

Since dumpon cannot be used during kernel initialization, the dumpdev
variable of loader(8) must be used to enable dumps for system panics
which occur during kernel initialization.

But I don't find 'dumpdev' referenced anywhere under /usr/src/sys/boot/. Is
the documentation wrong?

Regards,

Brian.
Doug White
2005-04-30 02:18:06 UTC
Permalink
Post by Brian Candler
Post by Andre Guibert de Bruet
Post by Danny Braniss
i can't use dumpon, since the kernel is panicking on boot, so
dumpdev="/dev/ar0s1b"
db> call doadump
Cannot dump. No dump device defined.
0x25
i need this is for current 6.0
thanks,
danny
That directive, along with dumpdir, would be set in /etc/rc.conf.
Since dumpon cannot be used during kernel initialization, the dumpdev
variable of loader(8) must be used to enable dumps for system panics
which occur during kernel initialization.
But I don't find 'dumpdev' referenced anywhere under /usr/src/sys/boot/. Is
the documentation wrong?
It wouldn't be there, but it alos loks like that tunable has gone away
when GEOM took over definign the dump device. Now it needs a struct to
specify the target, and you wouldn't be able to set it until way late in
the boot anyway (when GEOM attaches the disks).
--
Doug White | FreeBSD: The Power to Serve
***@gumbysoft.com | www.FreeBSD.org
Brian Fundakowski Feldman
2005-04-30 16:28:45 UTC
Permalink
Post by Doug White
Post by Brian Candler
Post by Andre Guibert de Bruet
Post by Danny Braniss
i can't use dumpon, since the kernel is panicking on boot, so
dumpdev="/dev/ar0s1b"
db> call doadump
Cannot dump. No dump device defined.
0x25
i need this is for current 6.0
thanks,
danny
That directive, along with dumpdir, would be set in /etc/rc.conf.
Since dumpon cannot be used during kernel initialization, the dumpdev
variable of loader(8) must be used to enable dumps for system panics
which occur during kernel initialization.
But I don't find 'dumpdev' referenced anywhere under /usr/src/sys/boot/. Is
the documentation wrong?
It wouldn't be there, but it alos loks like that tunable has gone away
when GEOM took over definign the dump device. Now it needs a struct to
specify the target, and you wouldn't be able to set it until way late in
the boot anyway (when GEOM attaches the disks).
Once that point has been reached there's little technical reason that
it couldn't automagically pick up a loader environment variable, or by
adjustable by a DDB command. Way back when, you could, after having
reached the appropriate part of the boot sequence, do something much
like:

db> show disk/ad0s1b
struct cdev *=0xc2f00000
db> w dumpdev

In this case, you would presumably be able to do this by booting into
DDB early and setting "break execve" to stop right before init is
executed. Of course, this method wouldn't be particularly useful if
the problem is occurring even before that. The easiest potential
location I can think of to stick a tunable would be just before the
vfs_mountroot() in start_init(), but then after moving the g_waitidle()
from vfs_mountroot() to just before this check in start_init().
--
Brian Fundakowski Feldman \'[ FreeBSD ]''''''''''\
<> ***@FreeBSD.org \ The Power to Serve! \
Opinions expressed are my own. \,,,,,,,,,,,,,,,,,,,,,,\
Loading...