3.7 Minimizing Drops

Because DTrace buffers some aggregation data in the kernel, space might not be available when a new key is added to an aggregation. In this case, the data will be dropped, a counter will be incremented, and dtrace generates a message indicating an aggregation drop. This situation rarely occurs because DTrace keeps state information, consisting of the aggregation's key and intermediate results, at user level where space can grow dynamically. In the unlikely event that an aggregation drop occurs, you can increase the aggregation buffer size with the aggsize option to reduce the likelihood of drops. You can also use this option to minimize the memory footprint of DTrace. As with any size option, aggsize can be specified with any size suffix. The resizing policy of this buffer is dictated by the bufresize option. For more information about buffering, see Chapter 5, Buffers and Buffering. For more information about options, see Chapter 10, Options and Tunables.

An alternative method to eliminate aggregation drops is to increase the rate at which aggregation data is consumed at user level. This rate defaults to once per second, and may be explicitly tuned with the aggrate option. As with any rate option, aggrate can be specified with any time suffix, but defaults to rate-per-second. For more information about the aggsize option, see Chapter 10, Options and Tunables.