Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You should really look at Dtrace. It has the ability to do this sort of thing. </p> <pre><code>#!/usr/sbin/dtrace -s /* * bitesize.d - analyse disk I/O size by process. * Written using DTrace (Solaris 10 build 63). * * This produces a report for the size of disk events caused by * processes. These are the disk events sent by the block I/O driver. * * If applications must use the disks, we generally prefer they do so * sequentially with large I/O sizes. * * 15-Jun-2005, ver 1.00 * * USAGE: bitesize.d # wait several seconds, then hit Ctrl-C * * FIELDS: * PID process ID * CMD command and argument list * value size in bytes * count number of I/O operations * * NOTES: * The application may be requesting smaller sized operations, which * are being rounded up to the nearest sector size or UFS block size. * To analyse what the application is requesting, DTraceToolkit programs * such as Proc/fddist may help. * * SEE ALSO: seeksize.d, iosnoop * * Standard Disclaimer: This is freeware, use at your own risk. * * 31-Mar-2004 Brendan Gregg Created this, build 51. * 10-Oct-2004 " " Rewrote to use the io provider, build 63. */ #pragma D option quiet /* * Print header */ dtrace:::BEGIN { printf("Sampling... Hit Ctrl-C to end.\n"); } /* * Process io start */ io:::start { /* fetch details */ this-&gt;size = args[0]-&gt;b_bcount; cmd = (string)curpsinfo-&gt;pr_psargs; /* store details */ @Size[pid,cmd] = quantize(this-&gt;size); } /* * Print final report */ dtrace:::END { printf("\n%8s %s\n","PID","CMD"); printa("%8d %s\n%@d\n",@Size); } </code></pre> <p>From <a href="http://developer.apple.com/documentation/Darwin/Reference/ManPages/man1/bitesize.d.1m.html" rel="nofollow noreferrer">here</a>.</p> <p>To run use </p> <pre><code>sudo dtrace -s bitsize.d </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload