From owner-freebsd-questions Mon Apr 17 16:36:31 2000 Delivered-To: freebsd-questions@freebsd.org Received: from freebie.lemis.com (freebie.lemis.com [192.109.197.137]) by hub.freebsd.org (Postfix) with ESMTP id ABCE637B5A8 for ; Mon, 17 Apr 2000 16:36:25 -0700 (PDT) (envelope-from grog@freebie.lemis.com) Received: (from grog@localhost) by freebie.lemis.com (8.9.3/8.9.0) id JAA05418; Tue, 18 Apr 2000 09:03:28 +0930 (CST) Date: Tue, 18 Apr 2000 09:03:28 +0930 From: Greg Lehey To: "Nandakumar.p.k" Cc: FreeBSD Questions Subject: Re: Debugging kernel using remote gdb Message-ID: <20000418090327.B514@freebie.lemis.com> References: <38FAEE09.4BB366B9@procsys.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0pre2i In-Reply-To: <38FAEE09.4BB366B9@procsys.com> Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-418-838-708 WWW-Home-Page: http://www.lemis.com/~grog X-PGP-Fingerprint: 6B 7B C3 8C 61 CD 54 AF 13 24 52 F8 6D A4 95 EF Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Monday, 17 April 2000 at 16:27:13 +0530, Nandakumar.p.k wrote: > Hi, > > I am not able to directly send the questions to freebsd - questions > hence i am sending this to you. We need to understand why you can't send to -questions. Do you have DNS problems? > We were trying to debug the kernel using remote gdb. We have followed > the instructions given in the Freebsd handbook. OK, I don't have time to look at this now, but I'll try later. In the meantime, I'm forwarding this to FreeBSD-questions. > The host and the target machine were connected using a null modem cable > which was tested using Pcplus utility in DOS. In both the machines the > cable is connected to the COM1 port. The cable has 3 pins connected. Tx > to Rx. Rx to Tx and common ground. With this we are able to send > characters from one machine to other using the terminal emulation pacage > Pcplus in DOS. > > The steps which we followed were as follows. > In the host machine > 1. Made a copy of the GENERIC kernel called MYKERNEL. > 2. The follwing additions were made to MYKERNEL > options DDB > device sio0 at isa? port "IO_COM1" flags 0x080 > 3. Compiled using config -g and installed MYKERNEL . > 4. Made a copy of the kernel , kernel.debug > 5. Copied the kernel.debug to the target machine. > > In the target machine > 1. Strip -x kernel.debug & then reboot. > 2. At the boot prompt ,loaded kernel.debug > 3. Opened the debugger using boot -d > > In the host machine > 1. cd /usr/src/sys/compile/MYKERNEL > 2. gdb -k kernel > 3. (kgdb) target remote /dev/cuaa0 > > In the target > 1.db>gdb > 2. s > > Now the following error message was displayed in the host > Ignoring packet error,continuing.. > Ignoring packet error,continuing.. > Ignoring packet error,continuing.. > Could'nt establish connection to remote target > Malformed response to offset query,timeout > > Any idea what is happening here ? > > Regards, > Nandan > > -- When replying to this message, please copy the original recipients. For more information, see http://www.lemis.com/questions.html Finger grog@lemis.com for PGP public key See complete headers for address and phone numbers To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message