Tracing Disk Activity

Hanspeter Roth hampi at rootshell.be
Sun Nov 21 08:00:43 PST 2004


  On Nov 21 at 14:00, David Jenkins spoke:

> On Sun, 21 Nov 2004 10:33:47 +0100, Hanspeter Roth <hampi at rootshell.be> wrote:
> > Hello,
> > 
> > I have set an idle timeout for the hard-disk. But when there is no
> > user activity there are frequent disk accesses.
> > How can one trace disk access?
> > I'd like to know the kind of access and on which files/directories/
> > nodes. I'd like to log on the console or on a memory disk file.
> 
> There may be a much better way of doing this but have a look at fstat(1).

Fstat(1) seems to take snapshots only and doesn't show # of bytes
transfered. Using fstat by polling frequently misses programs run
between poll.

I'd like a tool that displays in real-time (similar to tcpdump).

-Hanspeter


More information about the freebsd-questions mailing list