STREAMS/UX for the HP 9000 Reference Manual

171
Debugging STREAMS/UX Modules and Drivers
Generating and Retrieving System Core Dumps
Generating and Retrieving System Core Dumps
HP-UX will attempt to create a snapshot of physical memory and register
contents before it stops running. This snapshot can assist engineers in
determining the cause of the problem because it holds a record of what the
system was doing at the time it crashed. The correct name for this snapshot
is a core dump. The default location for this snapshot is the primary swap
area, but it is possible to configure systems to put the snapshot on another
disk device. See the System Administration Tasks manuals for the Series 700
and the Series 800 for information on configuring dump devices.
A core dump is composed of two files, a core file and an object file. The
core file is an image of the system's physical memory and register contents at
the time of a crash. The object file is the kernel file, /stand/vmunix.
To retrieve a core dump, the program /usr/sbin/savecore must be executed.
savecore will retrieve the core file from the swap device, along with a copy
of the system's kernel file, and save both in a specified directory. The core
file and the kernel file make up the core dump pair (for example, vmcore.N
and vmunix.N where N is a number that associates a core dump pair).
adb and strdb require that both members of a core dump pair be present. In
addition, it is very important that these members match for adb and strdb to
be effective. They must match because the kernel (vmunix.N) file contains
information which is used by adb and strdb as a road map into the core
(vmcore.N) file.
Setting Up Your System To Save a Core Dump
In order to have system core dumps saved automatically during boot-up, the
savecore function must be enabled in the system’s /etc/rc.config file. Search
this file for the string SAVECORE and follow the instructions in the
comments.