bin/71690: inaccurate information in systat(1) manpage
w at wrzask.pl
Sun Sep 12 18:30:27 PDT 2004
>Synopsis: inaccurate information in systat(1) manpage
>Arrival-Date: Mon Sep 13 01:30:22 GMT 2004
>Originator: Zdzis³aw Korzeñ
>Release: FreeBSD 4.x, 5.x, 6.x (all trees)
System: FreeBSD zikkurat.wrzask.pl 5.3-BETA2 FreeBSD 5.3-BETA2 #9: Sun Aug 29 14:24:19 CEST 2004 root at zikkurat.wrzask.pl:/usr/obj/usr/src/sys/SIN i386
The manpage for systat(1) is not accurate on what exacly is displayed
by the "vmstat" systat mode. It describes all the elements pretty well.
In the description of various virtual memory elements (like virtual/real
memory pages, active/inactive/wired pages etc.) it says that the numbers
displayed by systat are in page units. This is not true - the normal
page size is 4kB on an i386, and the numbers displayed are apparently
in kilobyte units (I have checked that on several machines, having say
100000 total real pages on a 128MB RAM machine is impossible;
sysctl vm.vmtotal confirms that, comparing some numbers to the
top(1) output was also enlightening).
So, to make things clear, the manpage should state that the numbers
are not number of pages, but number of kilobytes in pages allocated
for something. It's also worth noting that not every 'number of pages'
in the display actually means 'number of kilobytes in pages'; it does not
affect page counts after 'daefr' or zero-fill page counts.
The display may be somewhat confusing, as the units (pages
and kilobytes) are mixed with each other and one has to remember
which counter has which units. But that's another issue..
That's my proposal, it isn't very elegant, but at least makes
it clear which counter are in pages, which in kilobytes.
--- systat.1.old Mon Sep 13 02:45:30 2004
+++ systat.1 Mon Sep 13 03:22:07 2004
@@ -301,15 +301,16 @@
active processes, that is processes that have run in the previous
The second row reports on memory usage of all processes.
-The first column reports on the number of physical pages
-claimed by processes.
-The second column reports the number of physical pages that
-are devoted to read only text pages.
+The first column reports on the number of kilobytes in
+physical pages claimed by processes.
+The second column reports the number of kilobytes in
+physical pages that are devoted to read only text pages.
The third and fourth columns report the same two figures for
-virtual pages, that is the number of pages that would be
+virtual pages, that is the number of kilobytes in
+pages that would be
needed if all processes had all of their pages.
-Finally the last column shows the number of physical pages
-on the free list.
+Finally the last column shows the number of kilobytes in
+physical pages on the free list.
Below the memory display is a list of the
average number of processes (over the last refresh interval)
@@ -367,11 +368,11 @@
pages copied on write (`cow'),
pages zero filled on demand (`zfod'),
slow (on-the-fly) zero fills percentage (`%slo-z'),
-pages wired down (`wire'),
-active pages (`act'),
-inactive pages (`inact'),
-pages on the buffer cache queue (`cache'),
-number of free pages (`free'),
+kilobytes in pages wired down (`wire'),
+kilobytes in active pages (`act'),
+kilobytes in inactive pages (`inact'),
+kilobytes in pages on the buffer cache queue (`cache'),
+number of kilobytes in free pages (`free'),
pages freed by the page daemon (`daefr'),
pages freed by exiting processes (`prcfr'),
pages reactivated from the free list (`react'),
More information about the freebsd-bugs