LKML Archive on
help / color / mirror / Atom feed
* Two versions of the truth (Documentation/{filesystems/proc.txt,sysctl/vm.txt}
@ 2007-01-13  9:51 Toon van der Pas
  0 siblings, 0 replies; only message in thread
From: Toon van der Pas @ 2007-01-13  9:51 UTC (permalink / raw)
  To: Linux Kernel Mailing List


I was looking for a description of the kernel parameter page-cluster
and found two versions that appear to be very different to me.
(see the two text fragments below)

The first one talks about the clusting of pages on a page fault,
when pages need to be read into memory.
The second one talks about the number of pages written to swap in
a single attempt.

Which one is correct?
I'm inclined to choose the first description.
The second one appears to be wrong to me because paged-in pages are
simply evicted from the page cache when need be, they are never
written out to swap. At least, that's what I've always thought.

Can anybody help me out?

8< - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -


The Linux VM subsystem avoids excessive disk seeks by reading
multiple pages on a page fault. The number of pages it reads
is dependent on the amount of memory in your machine.

The number of pages the kernel reads in at once is equal to
2 ^ page-cluster. Values above 2 ^ 5 don't make much sense
for swap because we only cluster swap data in 32-page groups.


page-cluster controls the number of pages which are written to swap
in a single attempt.  The swap I/O size.

It is a logarithmic value - setting it to zero means "1 page",
setting it to 1 means "2 pages", setting it to 2 means "4 pages",

The default value is three (eight pages at a time).  There may be
some small benefits in tuning this to a different value if your
workload is swap-intensive.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-01-13  9:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-13  9:51 Two versions of the truth (Documentation/{filesystems/proc.txt,sysctl/vm.txt} Toon van der Pas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).