]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - gnu/usr.bin/gdb/kgdb/kgdb.1
MFC 320675: Add deprecation notices for gdb and kgdb.
[FreeBSD/stable/10.git] / gnu / usr.bin / gdb / kgdb / kgdb.1
1 .\" Copyright (c) 2004 Marcel Moolenaar
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
14 .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
15 .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
16 .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
17 .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
18 .\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
19 .\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
20 .\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
21 .\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\" $FreeBSD$
26 .\"
27 .Dd July 5, 2017
28 .Dt KGDB 1
29 .Os
30 .Sh NAME
31 .Nm kgdb
32 .Nd "kernel debugger"
33 .Sh SYNOPSIS
34 .Nm
35 .Op Fl a | Fl f | Fl fullname
36 .Op Fl b Ar rate
37 .Op Fl q | Fl quiet
38 .Op Fl v
39 .Op Fl w
40 .Op Fl d Ar crashdir
41 .Op Fl c Ar core | Fl n Ar dumpnr | Fl r Ar device
42 .Op Ar kernel Op Ar core
43 .Sh DEPRECATION NOTICE
44 This version of
45 .Nm
46 is deprecated and will be removed from future versions of the
47 .Fx
48 base system.
49 A newer version of
50 .Nm
51 is available from ports or packages
52 (devel/gdb).
53 .Sh DESCRIPTION
54 The
55 .Nm
56 utility is a debugger based on
57 .Xr gdb 1
58 that allows debugging of kernel core files.
59 .Pp
60 The options are as follows:
61 .Bl -tag -width ".Fl d Ar crashdir"
62 .It Fl a
63 Increase the annotation level.
64 An annotation level of 1 features the historical
65 .Fl fullname
66 option of
67 .Xr gdb 1 .
68 This is useful when running
69 .Nm
70 in Emacs.
71 The
72 .Fl f
73 or
74 .Fl fullname
75 options are supported for backward compatibility as well.
76 .It Fl b Ar rate
77 Set the baudrate to
78 .Ar rate .
79 .It Fl q
80 Suppress printing of the banner when the debugger starts.
81 The
82 .Fl quiet
83 form is supported for compatibility as well.
84 .It Fl v
85 Increase verbosity.
86 .It Fl w
87 Opens kmem-based targets in read-write mode.
88 (This is identical to what
89 .Fl -wcore
90 used to do in previous
91 gdb versions for
92 .Fx . )
93 .It Fl d Ar crashdir
94 Use
95 .Ar crashdir
96 instead of the default,
97 .Pa /var/crash
98 to locate kernel core dump files in.
99 The name
100 .Pa vmcore.
101 plus the dump number will be appended to determine
102 the actual dump file name.
103 .It Fl c Ar core
104 Explicitly use
105 .Ar core
106 as the core dump file.
107 .It Fl n Ar dumpnr
108 Use the kernel core dump file numbered
109 .Ar dumpnr
110 for debugging.
111 .It Fl r Ar device
112 Use
113 .Ar device
114 to connect
115 .Nm
116 to for a remote debugging session.
117 .El
118 .Pp
119 The
120 .Fl c , n ,
121 and
122 .Fl r
123 options are mutually exclusive.
124 .Pp
125 Optionally, the name of the kernel symbol file and
126 the name of the core dump file can be supplied on the
127 command-line as positional arguments.
128 If no kernel symbol file name has been given, the
129 symbol file of the currently running kernel will be
130 used.
131 If no core dump file has been specified through either
132 of the options or the last command-line argument,
133 .Pa /dev/mem
134 will be opened to allow debugging the currently running
135 kernel.
136 .Sh FILES
137 .Bl -tag -width ".Pa /var/crash"
138 .It Pa /dev/mem
139 Default memory image to open if no core dump file
140 has been specified.
141 .It Pa /var/crash
142 Default directory to locate kernel core dump files.
143 .El
144 .Sh SEE ALSO
145 .Xr gdb 1
146 .Sh HISTORY
147 The
148 .Nm
149 utility first appeared in its current form in
150 .Fx 5.3 .