mirror of
https://github.com/Stichting-MINIX-Research-Foundation/netbsd.git
synced 2025-09-10 15:46:33 -04:00
52 lines
2.9 KiB
Plaintext
52 lines
2.9 KiB
Plaintext
The following is a demonstration of the vmstat-p.d script,
|
|
|
|
|
|
We run both vmstat-p.d and the original vmstat(1M) command at the same time
|
|
to compare outputs,
|
|
|
|
$ vmstat -p 1
|
|
memory page executable anonymous filesystem
|
|
swap free re mf fr de sr epi epo epf api apo apf fpi fpo fpf
|
|
1144488 142456 2 8 1 0 0 0 0 0 0 0 0 2 1 1
|
|
1063812 84472 18 92 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050404 75108 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050404 75108 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050404 75108 476 150 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050184 74772 73 0 0 0 0 0 0 0 0 0 0 788 0 0
|
|
1050400 74988 2371 173 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75100 1057 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75100 2 0 0 0 0 0 0 0 0 0 0 4 0 0
|
|
1050400 75100 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75100 4529 172 0 0 0 0 0 0 0 0 0 192 0 0
|
|
1050400 75104 0 0 0 0 0 0 0 0 0 0 0 467 0 0
|
|
1050400 75104 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
# ./vmstat-p.d
|
|
memory page executable anonymous filesystem
|
|
swap free re mf sr epi epo epf api apo apf fpi fpo fpf
|
|
1050404 75108 8 80 0 0 0 0 0 0 0 0 0 0
|
|
1050404 75108 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050404 75108 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050180 74768 2216 608 0 0 0 0 0 0 0 568 0 0
|
|
1050400 74988 4 0 0 0 0 0 0 0 0 228 0 0
|
|
1050400 75100 13852 700 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75100 8 0 0 0 0 0 0 0 0 4 0 0
|
|
1050400 75100 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75100 0 0 0 0 0 0 0 0 0 0 0 0
|
|
1050400 75104 18480 700 0 0 0 0 0 0 0 668 0 0
|
|
1050400 75104 0 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
Above we can see the columns are corresponding well. "re" and "mf" in the
|
|
DTrace output appear four times as large as they should be, because in the
|
|
DTrace output we are printing Kbs not page counts (for consistancy).
|
|
|
|
The DTrace output lacks the "summary since boot" line, as it is not using
|
|
Kstat to fetch this data.
|
|
|
|
|
|
The vmstat-p.d script is not intended itself as a useful program, rather it
|
|
is intended as a starting point for other DTrace scripts; a starting point
|
|
of familiar statistics to provide the programmer with a "common ground"
|
|
of knowledge.
|
|
|