xref: /openbsd/usr.bin/kdump/kdump.1 (revision cca36db2)
1.\"	$OpenBSD: kdump.1,v 1.22 2012/04/10 20:39:37 mikeb Exp $
2.\"
3.\" Copyright (c) 1990, 1993
4.\"	The Regents of the University of California.  All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. Neither the name of the University nor the names of its contributors
15.\"    may be used to endorse or promote products derived from this software
16.\"    without specific prior written permission.
17.\"
18.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
19.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
22.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28.\" SUCH DAMAGE.
29.\"
30.\"	from: @(#)kdump.1	8.1 (Berkeley) 6/6/93
31.\"
32.Dd $Mdocdate: April 10 2012 $
33.Dt KDUMP 1
34.Os
35.Sh NAME
36.Nm kdump
37.Nd display kernel trace data
38.Sh SYNOPSIS
39.Nm kdump
40.Bk -words
41.Op Fl dHlnRrTXx
42.Op Fl e Ar emulation
43.Op Fl f Ar file
44.Op Fl m Ar maxdata
45.Op Fl p Ar pid
46.Op Fl t Op ceinsw
47.Ek
48.Sh DESCRIPTION
49.Nm
50displays the kernel trace files produced with
51.Xr ktrace 1
52in human-readable format.
53By default, the file
54.Pa ktrace.out
55in the current directory is displayed, unless overridden by the
56.Fl f
57option.
58.Pp
59The options are as follows:
60.Bl -tag -width Ds
61.It Fl d
62Display all numbers in decimal.
63By default, values are printed out in hexadecimal.
64.It Fl e Ar emulation
65Interpret system call maps assuming the named emulation instead of
66.Qq bsd .
67For example, to view trace output from a Linux binary, use
68.Fl e Ar linux .
69.It Fl f Ar file
70Display the specified file instead of
71.Pa ktrace.out .
72.It Fl H
73Display thread identifiers.
74.It Fl l
75Loop reading the trace file, once the end-of-file is reached, waiting for
76more data.
77.It Fl m Ar maxdata
78Display at most
79.Ar maxdata
80bytes when decoding I/O.
81.It Fl n
82Suppress ad hoc translations.
83Normally
84.Nm
85tries to decode many system calls into a more human-readable format.
86For example,
87.Xr ioctl 2
88values are replaced with the macro name and
89.Va errno
90values are replaced with the
91.Xr strerror 3
92string.
93Suppressing this feature yields a more consistent output format and is
94easily amenable to further processing.
95.It Fl p Ar pid
96Show output only for the
97.Ar pid
98specified.
99.It Fl R
100Display relative timestamps (time since previous entry).
101.It Fl r
102When decoding the name in
103.Xr sysctl 3
104CALL records or structure members in STRU records
105(UIDs, GIDs, dates, etc),
106display symbolically instead of numerically.
107.It Fl T
108Display absolute timestamps for each entry (seconds since the Epoch).
109.It Fl t Op ceinstw
110Selects which tracepoints to display.
111See the
112.Fl t
113option of
114.Xr ktrace 1
115for the definitions of the flags.
116.It Fl X
117Display I/O data with hexadecimal data and printable ASCII characters
118side by side.
119.It Fl x
120Display I/O data in hexadecimal.
121.El
122.Sh FILES
123.Bl -tag -width ktrace.out -compact
124.It Pa ktrace.out
125default ktrace dump file
126.El
127.Sh SEE ALSO
128.Xr ktrace 1
129.Sh HISTORY
130The
131.Nm
132command appeared in
133.Bx 4.4 .
134