From owner-freebsd-hackers Wed Aug 30 01:22:30 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.FreeBSD.org (8.6.11/8.6.6) id BAA18205 for hackers-outgoing; Wed, 30 Aug 1995 01:22:30 -0700 Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.FreeBSD.org (8.6.11/8.6.6) with ESMTP id BAA18186 for ; Wed, 30 Aug 1995 01:22:14 -0700 Received: from sax.sax.de by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id KAA20457; Wed, 30 Aug 1995 10:20:52 +0200 Received: by sax.sax.de (8.6.11/8.6.12-s1) with UUCP id KAA29459; Wed, 30 Aug 1995 10:20:51 +0200 Received: (from j@localhost) by uriah.heep.sax.de (8.6.12/8.6.9) id JAA02080; Wed, 30 Aug 1995 09:23:14 +0200 From: J Wunsch Message-Id: <199508300723.JAA02080@uriah.heep.sax.de> Subject: Re: Chasing the ghost (DDB usage tips). To: freebsd-hackers@freebsd.org (FreeBSD hackers) Date: Wed, 30 Aug 1995 09:23:13 +0200 (MET DST) Cc: rashid@haven.ios.com (Rashid Karimov.) Reply-To: freebsd-hackers@freebsd.org (FreeBSD hackers) In-Reply-To: <199508292217.SAA27856@haven.ios.com> from "Rashid Karimov." at Aug 29, 95 06:17:22 pm Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) X-Phone: +49-351-2012 669 X-Mailer: ELM [version 2.4 PL23] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Content-Length: 1316 Sender: hackers-owner@freebsd.org Precedence: bulk As Rashid Karimov. wrote: > > So if any1 here can provide any tip on DDB usage - > that would be great. Man page is not too helpful > in this sense, /usr/share/FAQ/Text/kernel-debug.FAQ > for example , how can I find if the SCSI driver > is fine and is not locked ? If it is locked - in which > routine and what parameters were passed to it ... > How to find the processes waiting for the resources > and find the reason for them to be in the wait state ? There's a `ps' command, and often you can also guess certain things from the stack backtrace. When looking deep inside some scsi routines, have a printed copy of the sources around, or a second machine where you can browse through the code. Remember the command ``x/iA ,18'' to get a disassembled listing of some portion of code (``x,18'' for the next chunk). You'll need to have a ``feeling'' of what the compiler does. Clearly differentiate between p(rint) and (e)x(amine). Applied to a variable, print will print its address, while examine will print the contents. OTOH, you cannot examine a register, but you can print it (this is usually easier to watch then `show registers'). -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ Never trust an operating system you don't have sources for. ;-)