kgdb on sparc64

Marius Strobl marius at alchemy.franken.de
Mon Nov 3 14:11:14 PST 2008


On Mon, Nov 03, 2008 at 01:02:15PM +0100, Ruben de Groot wrote:
> 
> Hi,
> 
> After upgrading to 7.1-PRERELEASE last month I'm seeing some 
> spontaneous reboots with crash dumps on this Netra X1. How
> can I debug this as kgdb seems not to be working?
> 
> # uname -r
> 7.1-PRERELEASE
> # kgdb /usr/obj/usr/src/sys/N4I/kernel.debug /var/crash/vmcore.1
> GNU gdb 6.1.1 [FreeBSD]
> Copyright 2004 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you are
> welcome to change it and/or distribute copies of it under certain conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for details.
> This GDB was configured as "sparc64-marcel-freebsd"...^C
> GDB can't read core files on this machine.
> 

I've never had much luck with kgdb(1) on any arch and use
devel/gdb53 which still has '-k' instead (for sparc64 just
remove the BROKEN from the port Makefile; the problem
leading to that one being added was fixed some time a go).
For your purposes it's probably simpler to just build a
kernel with debugger by adding "options DDB", "options KDB"
and "makeoptions DEBUG=-g". Then when the kernel panics
just enter "backtrace" on the console. With a X1 you
most likely use serial console anyway so you can easily
capture the output.

Marius



More information about the freebsd-sparc64 mailing list