Systems Performance 2nd Ed.

BPF Performance Tools book

Recent posts:
Blog index

DTrace pid Provider Links

19 Feb 2011

I originally posted this at

I've been writing posts to explain the DTrace pid provider. Not just its features, which are documented in many places, but also its hazards and limitations. Many of these I learned the hard way during the last six years of using this provider in test, development and production. The posts are:

These may also serve as a practical introduction and tutorial to the pid provider.

I've been wanting to share some useful pid provider-based scripts, but first needed to explain some of the risks, as I have now done in these posts. You can really shoot yourself in the foot with this provider, especially regarding overhead in the short term and script stability in the longer term.

For advanced reading on the pid provider, see the following:

To use this provider, you'll need a system with DTrace and the pid provider, and privilege to use it (which usually means root access). Joyent SmartMachines typically have access to DTrace and the pid provider from the root account, and privileges can be configured for other accounts to use it.