I feel obliged to point out that this blog post is roughly 5 years old. People change, opinions evolve. In just a few years, vast technological landscapes can shift. And don't get me started on config files. Please consider this text in the context of its time.

Historic values are sometimes quite useful to have an overview of what’s happened in the past on your system, but quite often it’s only something you have to remove for analysis as those values may skew any statistics you are doing on them. vmstat is one of the commands with a first output line containing historical data with limited value.

In an SRU of Solaris 11.4 it got a new option to suppress this first line. The default is still to print it as scripts may depend on the existence of this line of output, but with the -Q option vmstat won’t print it any longer.

Without the option, you will recognize that the first line doesn’t really represent the current state of things which is more closely represented by the second line.

root@solaris:~#  vmstat  1 2
kthr      memory            page            disk          faults      cpu
r b w   swap  free  re  mf pi po fr de sr s0 s1 s2 --   in   sy   cs us sy id
0 0 0 2190112 262920 9  42  0  0  0  0  0  7  0 10  0  364 1119  345  0  5 95
1 0 0 2115764 185120 7  43  0  0  0  0  0  0  0  0  0  347  966  265  0  4 96

With -Q both lines contain a much closer representation.

root@solaris:~#  vmstat -Q  1 2
 kthr      memory            page            disk          faults      cpu
 r b w   swap  free  re  mf pi po fr de sr s0 s1 s2 --   in   sy   cs us sy id
 0 0 0 2115744 185968 7  38  0  0  0  0  0  0  0  0  0  343 1150  266  1  4 95
 0 0 0 2115744 185856 0   5  0  0  0  0  0  0  0 89  0  393  927  398  0  3 97
Written by

Joerg Moellenkamp

Grey-haired, sometimes grey-bearded Windows dismissing Unix guy.