db2top -k

Some of the information that db2top reports are statistics measured from the last reset of the snapshot. There is also a “delta” mode in which these same statistics are reset every second regardless of the refresh interval. This “delta” mode is the default mode that db2top runs in. Today, we will look at how the -k option lets you override this default. For example, in this default mode, the sessions screen shows columns such as “Delta RowsRead/s”, “Delta RowsWritten/s”, “Delta IOReads/s”, and “Delta IOWrites/s”:

db2top Sessions screen showing deltas

You can override the “delta” mode on the command line by specifying the -k option. This causes db2top to measure the stats from the last reset of the snapshot. The example below shows the sessions screen again, though there are many other screens that can illustrate the same behavior. This time, db2top was launched with the -k option:

db2top Sessions screen showing data collected since last reset