From owner-freebsd-questions@FreeBSD.ORG Mon Jan 29 23:31:39 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 3614616A406 for ; Mon, 29 Jan 2007 23:31:39 +0000 (UTC) (envelope-from ohartman@mail.zedat.fu-berlin.de) Received: from outpost1.zedat.fu-berlin.de (outpost1.zedat.fu-berlin.de [130.133.4.66]) by mx1.freebsd.org (Postfix) with ESMTP id E726E13C4BD for ; Mon, 29 Jan 2007 23:31:38 +0000 (UTC) (envelope-from ohartman@mail.zedat.fu-berlin.de) Received: from inpost2.zedat.fu-berlin.de ([130.133.4.69]) by outpost1.zedat.fu-berlin.de (Exim 4.66) with esmtp (envelope-from ) id <1HBfyL-00036I-QF>; Tue, 30 Jan 2007 00:31:37 +0100 Received: from e178022029.adsl.alicedsl.de ([85.178.22.29] helo=[192.168.1.128]) by inpost2.zedat.fu-berlin.de (Exim 4.66) with esmtpsa (envelope-from ) id <1HBfyL-00033d-NQ>; Tue, 30 Jan 2007 00:31:37 +0100 Message-ID: <45BE83E3.8040107@mail.zedat.fu-berlin.de> Date: Tue, 30 Jan 2007 00:31:47 +0100 From: "O. Hartmann" User-Agent: Thunderbird 1.5.0.9 (X11/20070120) MIME-Version: 1.0 To: Bill Moran References: <45BE7BCD.3000009@mail.zedat.fu-berlin.de> <20070129180509.49217b93.wmoran@collaborativefusion.com> In-Reply-To: <20070129180509.49217b93.wmoran@collaborativefusion.com> X-Enigmail-Version: 0.94.1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Originating-IP: 85.178.22.29 Cc: freebsd-questions@freebsd.org Subject: Re: Command watching opened files by processes in FreeBSD 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, 29 Jan 2007 23:31:39 -0000 Bill Moran wrote: > In response to "O. Hartmann" : > > >> Hello out there, >> does FreeBSD has a nativ root-restricted facility watching opened files >> of a process or process group (like lsof or filemon)? >> > > Is fstat what you're looking for? > > Sorry for the noise. Yes, fstat could possibly that I wanted it for, but is there a way to make it look like a continious watching a process opening and closing files? fstat -p PID gives me a snapshot of the status quo as of the second I enter the command but that menas I could miss the right time point. Maybe something like ptrace will be better. Thanks a lot for the pretty fast answers! -- O. Hartmann