Polytropon freebsd at
Wed Sep 11 14:26:09 UTC 2013

On Wed, 11 Sep 2013 09:41:31 +0200, Pawel Sulewski wrote:
> How to recognize kernel panic and dump memory state onto USB device using C
> language?

The kernel has its own crash handling and will initiate the
writing of the proper image automatically. It will be stored
on the partition designated by the /etc/rc.conf setting
dumpdev="<device>", usually a swap partition, and at next
boot time that image will be written to a file in /var/crash,
if nothing else has been defined with dumpdir="<directory>"
(same file; see "man rc.conf" and /etc/defaults/rc.conf for
details). If you want to coredump to a USB device, you need
to configure this accordingly.

You can find more information about this topic in the following
manual pages: "man 2 sigaction", "man 8 crash", and "man 5 core".

Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

More information about the freebsd-questions mailing list