Hi, I know how to trace the number of bytes read/written by a program by summing the argument of that read/write syscall. However, the way the OS services read/write calls is in blocks. I wonder if it''s possible to trace the actual number of blocks read/written caused by the syscalls? -- This message posted from opensolaris.org
Matt.Ingenthron at Sun.COM
2008-Aug-13 20:11 UTC
[dtrace-discuss] tracing blocks behind I/O
Yi wrote:> Hi, > > I know how to trace the number of bytes read/written by a program by summing the argument of that read/write syscall. However, the way the OS services read/write calls is in blocks. I wonder if it''s possible to trace the actual number of blocks read/written caused by the syscalls? >Have a look at /usr/demo/dtrace/whoio.d for an example on how to get this info from the io provider. # dtrace -l -P io ID PROVIDER MODULE FUNCTION NAME 4088 io genunix biodone done 4089 io genunix biowait wait-done 4090 io genunix biowait wait-start 4099 io genunix default_physio start 4100 io genunix bdev_strategy start 4101 io genunix aphysio start 31690 io nfs nfs4_bio done 31691 io nfs nfs3_bio done 31692 io nfs nfs_bio done 31693 io nfs nfs4_bio start 31694 io nfs nfs3_bio start 31695 io nfs nfs_bio start - Matt -- Matt Ingenthron http://blogs.sun.com/mingenthron/ email: matt.ingenthron at sun.com