Handy hints for using dtrace on the Mac

I’m a big fan of Linux tools which allow you to monitor things in great detail. Some of my favorites are strace, the systemtap tools, and sysstat. Finding tools similar to these on a Mac is a little more difficult.

There’s a great blog post from Brendan Gregg’s blog that covers a lot of detail around dtrace and its related tools:

One of the handier tools is iosnoop. It gives you a much easier to read (and easier to generate) view of the disk I/O on your Mac. If you remember, I talked about how to do this in Linux in the systemtap post as well as the post about finding elusive sources of iowait. This could give you a lot of handy information if you’re staring at beachballs regularly while your disk drive churns.

Comments

  1. says

    I like the sysstat tools a lot too, except for iostat. I fixed that by writing my own: pt-diskstats.

    wget percona.com/get/pt-diskstats
    perl pt-diskstats

    Voila!

Leave a Reply

Your email address will not be published. Required fields are marked *