From owner-freebsd-questions Tue Nov 9 9:44:53 1999 Delivered-To: freebsd-questions@freebsd.org Received: from yana.lemis.com (yana.lemis.com [192.109.197.140]) by hub.freebsd.org (Postfix) with ESMTP id F374D14FD5 for ; Tue, 9 Nov 1999 09:44:36 -0800 (PST) (envelope-from grog@mojave.sitaranetworks.com) Received: from mojave.sitaranetworks.com ([199.103.141.157]) by yana.lemis.com (8.8.8/8.8.8) with ESMTP id EAA11463 for ; Wed, 10 Nov 1999 04:14:31 +1030 (CST) (envelope-from grog@mojave.sitaranetworks.com) Message-ID: <19991109105934.34058@mojave.sitaranetworks.com> Date: Tue, 9 Nov 1999 10:59:34 -0500 From: Greg Lehey To: vladimir-freebsd-questions@math.uic.edu, freebsd-questions@FreeBSD.ORG Subject: Re: ktrace'ing a running process Reply-To: Greg Lehey References: <19991109155300.2407.qmail@math.uic.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <19991109155300.2407.qmail@math.uic.edu>; from vladimir-freebsd-questions@math.uic.edu on Tue, Nov 09, 1999 at 03:53:00PM -0000 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tuesday, 9 November 1999 at 15:53:00 -0000, vladimir-freebsd-questions@math.uic.edu wrote: > I ran into a problem: ktrace -p PID produces > a 0 length file ktrace.out, and ktrace exits > immediately. The system is FBSD-3.3-STABLE. > What am I doing wrong? Not much. You're probably just assuming that it's a bug for ktrace to exit immediately, and in fact it's a feature. To stop the trace, enter 'ktrace -p PID -C'. The real question is: why is your process not producing any ktrace output? It may not be running, or it may be looping in user space. Remember that ktrace shows only the transitions between user and kernel space. If you don't have any such transitions, you won't get any output. What does 'ps lp PID' say? Greg -- 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