NetBSD/share/man/man8/man8.vax/crash.8

210 lines
8.4 KiB
Groff
Raw Normal View History

2002-12-21 15:56:35 +03:00
.\" $NetBSD: crash.8,v 1.9 2002/12/21 12:56:35 wiz Exp $
1997-10-19 17:02:43 +04:00
.\"
.\" Copyright (c) 1980, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
1993-03-21 12:45:37 +03:00
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\" 3. All advertising materials mentioning features or use of this software
.\" must display the following acknowledgement:
.\" This product includes software developed by the University of
.\" California, Berkeley and its contributors.
.\" 4. Neither the name of the University nor the names of its contributors
.\" may be used to endorse or promote products derived from this software
.\" without specific prior written permission.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
1997-10-19 17:02:43 +04:00
.\" from: @(#)crash.8 8.1 (Berkeley) 6/5/93
1993-03-21 12:45:37 +03:00
.\"
.Dd June 5, 1993
.Os
.Dt CRASH 8
.Sh NAME
.Nm crash
.Nd UNIX system failures
.Sh DESCRIPTION
1993-03-21 12:45:37 +03:00
This section explains what happens when the system crashes
and (very briefly) how to analyze crash dumps.
.Pp
1993-03-21 12:45:37 +03:00
When the system crashes voluntarily it prints a message of the form
.Pp
.Dl panic: why i gave up the ghost
.Pp
1993-03-21 12:45:37 +03:00
on the console, takes a dump on a mass storage peripheral,
and then invokes an automatic reboot procedure as
described in
.Xr reboot 8 .
1993-03-21 12:45:37 +03:00
(If auto-reboot is disabled on the front panel of the machine the system
will simply halt at this point.)
Unless some unexpected inconsistency is encountered in the state
of the file systems due to hardware or software failure, the system
will then resume multi-user operations.
.Pp
1993-03-21 12:45:37 +03:00
The system has a large number of internal consistency checks; if one
of these fails, then it will panic with a very short message indicating
which one failed.
In many instances, this will be the name of the routine which detected
the error, or a two-word description of the inconsistency.
A full understanding of most panic messages requires perusal of the
source code for the system.
.Pp
1993-03-21 12:45:37 +03:00
The most common cause of system failures is hardware failure, which
can reflect itself in different ways. Here are the messages which
are most likely, with some hints as to causes.
Left unstated in all cases is the possibility that hardware or software
error produced the message in some unexpected way.
.Bl -tag -width 8n -compact
.It iinit
1993-03-21 12:45:37 +03:00
This cryptic panic message results from a failure to mount the root filesystem
during the bootstrap process.
Either the root filesystem has been corrupted,
or the system is attempting to use the wrong device as root filesystem.
1997-03-08 17:02:43 +03:00
Usually, an alternative copy of the system binary or an alternative root
1993-03-21 12:45:37 +03:00
filesystem can be used to bring up the system to investigate.
.It Can't exec /sbin/init
1993-03-21 12:45:37 +03:00
This is not a panic message, as reboots are likely to be futile.
Late in the bootstrap procedure, the system was unable to locate
and execute the initialization process,
.Xr init 8 .
1993-03-21 12:45:37 +03:00
The root filesystem is incorrect or has been corrupted, or the mode
or type of /sbin/init forbids execution.
.It IO err in push
.It hard IO err in swap
1993-03-21 12:45:37 +03:00
The system encountered an error trying to write to the paging device
or an error in reading critical information from a disk drive.
The offending disk should be fixed if it is broken or unreliable.
.It realloccg: bad optim
.It ialloc: dup alloc
.It alloccgblk: cyl groups corrupted
.It ialloccg: map corrupted
.It free: freeing free block
.It free: freeing free frag
.It ifree: freeing free inode
.It alloccg: map corrupted
1993-03-21 12:45:37 +03:00
These panic messages are among those that may be produced
when filesystem inconsistencies are detected.
The problem generally results from a failure to repair damaged filesystems
after a crash, hardware failures, or other condition that should not
normally occur.
A filesystem check will normally correct the problem.
.It timeout table overflow
1993-03-21 12:45:37 +03:00
This really shouldn't be a panic, but until the data structure
involved is made to be extensible, running out of entries causes a crash.
If this happens, make the timeout table bigger.
.It KSP not valid
.It SBI fault
.It CHM? in kernel
1993-03-21 12:45:37 +03:00
These indicate either a serious bug in the system or, more often,
a glitch or failing hardware.
If SBI faults recur, check out the hardware or call
field service. If the other faults recur, there is likely a bug somewhere
in the system, although these can be caused by a flakey processor.
Run processor microdiagnostics.
.It machine check %x: Em description
.It \0\0\0machine dependent machine-check information
1993-03-21 12:45:37 +03:00
Machine checks are different on each type of CPU.
Most of the internal processor registers are saved at the time of the fault
and are printed on the console.
For most processors, there is one line that summarizes the type of machine
check.
2002-12-21 15:56:35 +03:00
Often, the nature of the problem is apparent from this message
1993-03-21 12:45:37 +03:00
and/or the contents of key registers.
The VAX Hardware Handbook should be consulted,
and, if necessary, your friendly field service people should be informed
of the problem.
.It trap type %d, code=%x, pc=%x
1993-03-21 12:45:37 +03:00
A unexpected trap has occurred within the system; the trap types are:
.Bd -literal -offset indent
1993-03-21 12:45:37 +03:00
0 reserved addressing fault
1 privileged instruction fault
2 reserved operand fault
3 bpt instruction fault
4 xfc instruction fault
5 system call trap
6 arithmetic trap
7 ast delivery trap
8 segmentation fault
9 protection fault
10 trace trap
11 compatibility mode fault
12 page fault
13 page table fault
.Ed
.Pp
1993-03-21 12:45:37 +03:00
The favorite trap types in system crashes are trap types 8 and 9,
indicating
a wild reference. The code is the referenced address, and the pc at the
time of the fault is printed. These problems tend to be easy to track
down if they are kernel bugs since the processor stops cold, but random
flakiness seems to cause this sometimes.
The debugger can be used to locate the instruction and subroutine
corresponding to the PC value.
If that is insufficient to suggest the nature of the problem,
more detailed examination of the system status at the time of the trap
usually can produce an explanation.
.It init died
1993-03-21 12:45:37 +03:00
The system initialization process has exited. This is bad news, as no new
users will then be able to log in. Rebooting is the only fix, so the
system just does it right away.
.It out of mbufs: map full
1993-03-21 12:45:37 +03:00
The network has exhausted its private page map for network buffers.
This usually indicates that buffers are being lost, and rather than
allow the system to slowly degrade, it reboots immediately.
The map may be made larger if necessary.
.El
.Pp
1993-03-21 12:45:37 +03:00
That completes the list of panic types you are likely to see.
.Pp
1993-03-21 12:45:37 +03:00
When the system crashes it writes (or at least attempts to write)
an image of memory into the back end of the dump device,
usually the same as the primary swap
area. After the system is rebooted, the program
.Xr savecore 8
1993-03-21 12:45:37 +03:00
runs and preserves a copy of this core image and the current
system in a specified directory for later perusal. See
.Xr savecore 8
1993-03-21 12:45:37 +03:00
for details.
.Pp
1993-03-21 12:45:37 +03:00
To analyze a dump you should begin by running
.Ic adb
2001-09-06 03:53:22 +04:00
with the
.Fl k
1993-03-21 12:45:37 +03:00
flag on the system load image and core dump.
If the core image is the result of a panic,
the panic message is printed.
Normally the command
.Dq $c
1993-03-21 12:45:37 +03:00
will provide a stack trace from the point of
the crash and this will provide a clue as to
what went wrong.
For more detail
see
.Dq Using ADB to Debug the UNIX Kernel .
.Sh SEE ALSO
.Xr gdb 1 ,
2002-07-04 21:35:44 +04:00
.Xr reboot 8
1993-03-21 12:45:37 +03:00
.br
.Dq VAX 11/780 System Maintenance Guide
1993-03-21 12:45:37 +03:00
and
.Dq VAX Hardware Handbook
1993-03-21 12:45:37 +03:00
for more information about machine checks.
.br
.Dq Using ADB to Debug the UNIX Kernel