Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 11 Mar 2007 14:42:50 +0900
From:      gnn@freebsd.org
To:        Julian Elischer <julian@elischer.org>
Cc:        FreeBSD Current <current@freebsd.org>
Subject:   Re: remote gdb (serial) for kernel..
Message-ID:  <m2r6rwpc85.wl%gnn@neville-neil.com>
In-Reply-To: <45EE0D92.9090702@elischer.org>
References:  <45EE0D92.9090702@elischer.org>

next in thread | previous in thread | raw e-mail | index | archive | help
At Tue, 06 Mar 2007 16:55:46 -0800,
julian wrote:
> 
> Anyone been doing this recently?
> 

Yes, on VMWare and Parallels only at the moment.

> should I use gdb or kgdb?

kgdb

> neither seems to work right..
> if you have had success in doing this recently, could you let me know
> what your settings have been?

In my kernel config file:

options         KDB                     # Enable kernel debugger support.
options         DDB                     # Support DDB.   
options         GDB                     # Support remote GDB.

In /boot/loader.conf:

hint.sio.1.flags=0x90
boot_gdb=1

This is on CURRENT.

devbox ? sudo kgdb -r /dev/cuad1 kernel
[GDB will not be able to debug user-mode threads: /usr/lib/libthread_db.so: Undefined symbol "ps_pglobal_lookup"]
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 "i386-marcel-freebsd".
Switching to remote protocol

Not perfect all the time but "works for me."

Best,
George



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?m2r6rwpc85.wl%gnn>