sampleproc(1m) USER COMMANDS sampleproc(1m)

sampleproc - sample processes on the CPUs. Uses DTrace.

sampleproc [hertz]

This program samples which process is on each CPU, at a particular configurable rate. This can be used as an estimate for which process is consuming the most CPU time.

Since this uses DTrace, only users with root privileges can run this command.

# sampleproc
# sampleproc 400

process ID
command name
number of samples
percent of CPU usage


DTrace Guide "profile Provider" chapter (

See the DTraceToolkit for further documentation under the Docs directory. The DTraceToolkit docs may include full worked examples with verbose descriptions explaining the output.

sampleproc will sample until Ctrl-C is hit.


June 9, 2005 version 0.70