From owner-freebsd-questions@FreeBSD.ORG Mon May 3 21:10:15 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 393C8106566B for ; Mon, 3 May 2010 21:10:15 +0000 (UTC) (envelope-from dkmcnulty@gmail.com) Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.157]) by mx1.freebsd.org (Postfix) with ESMTP id C35FB8FC13 for ; Mon, 3 May 2010 21:10:14 +0000 (UTC) Received: by fg-out-1718.google.com with SMTP id l26so959532fgb.13 for ; Mon, 03 May 2010 14:10:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=wycuNcVFrE960vqWaHiBbx1ND8SYRWN6z3cIPuK4nRU=; b=AIkXuXVXCfxS3ZKn9mXP76ImfUYLoJS0MsmqReDhficbMR5OT0SYfqr8Y7R3ETbV4n NxbWirmabcxgXEpY+p15vEA9m2AMyOGkVxzyzQRqo3MvzIr5Q0hmiR30UQ2ofA0LlJUe Itquo+tC5rZ3Fr2qQnLvlpr4znFeOd7EdXyZg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=BMLlFQTatVdHuvd6gJ6Wmopx7m+2a4vtsvJ7RJ5QoDVAvB+9CM2BiVOa3zfCFoq/n3 qiVoWdJ/4xVHI7Aklq/OFeaDgQxb/hc2qQEo80bOGkwd8dQ5NCci/hnL28A6+E5o98aN Vg2+6wUbTAD/pPGSg4KtIcXLB3EI+V6xMpq0o= MIME-Version: 1.0 Received: by 10.239.186.196 with SMTP id i4mr487234hbh.109.1272919198651; Mon, 03 May 2010 13:39:58 -0700 (PDT) Received: by 10.239.153.198 with HTTP; Mon, 3 May 2010 13:39:58 -0700 (PDT) Date: Mon, 3 May 2010 15:39:58 -0500 Message-ID: From: Dan McNulty To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: Finding out when a child process forks or calls exec X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 May 2010 21:10:15 -0000 Hi all, I am trying to port a debugging tool that uses the ptrace interface from Linux to FreeBSD. From what I can tell, the ptrace interface on FreeBSD is pretty similar to the Linux interface; however, it doesn't appear that the FreeBSD interface generate events when the child process forks, calls exec, creates a new LWP, etc. My question then is: Does FreeBSD provide any way to determine from a parent/tracing process if a child process has called fork, exec, exit, or created a new LWP? Thanks for your help, -Dan