On Mar 1, 2008, at 3:41 AM, Bill Shannon wrote:
> Running just plain "iosnoop" shows accesses to lots of files, but none
> on my zfs disk. Using "iosnoop -d c1t1d0" or "iosnoop -m /export/
> home/shannon"
> shows nothing at all. I tried /usr/demo/dtrace/iosnoop.d too, still
> nothing.
hi Bill
this came up sometime last year .. io:::start won't work since ZFS
doesn't call bdev_strategy() directly .. you'll want to use something
more like zfs_read:entry, zfs_write:entry and zfs_putpage or
zfs_getpage for mmap'd ZFS files
here's one i hacked from our discussion back then to track some
timings on files:
> cat zfs_iotime.d
#!/usr/sbin/dtrace -s
# pragma D option quiet
zfs_write:entry,
zfs_read:entry,
zfs_putpage:entry,
zfs_getpage:entry
{
self->ts = timestamp;
self->filepath = args[0]->v_path;
}
zfs_write:return,
zfs_read:return,
zfs_putpage:return,
zfs_getpage:return
/self->ts && self->filepath/
{
printf("%s on %s took %d nsecs\n", probefunc,
stringof(self->filepath), timestamp - self->ts);
self->ts = 0;
self->filepath = 0;
}
---
.je
_______________________________________________
dtrace-discuss mailing list
[email protected]