Subject: System slowdown during paging (was Re: NetBSD stable on sun4m SS4?)
To: None <port-sparc@NetBSD.ORG>
From: Sean Doran <smd@chops.icp.net>
List: port-sparc
Date: 08/10/1996 04:55:20
-----BEGIN PGP SIGNED MESSAGE-----

James Graham - Systems Anarchist <greywolf@starwolf.com> writes:

> (3)	When your system decides to page for whatever reason, it seems to
> 	want to page out Lots O' Pages at once; i.e. suddenly a heap of
> 	pages expire.  The system grinds to a halt while the paging code
> 	takes over all available cycles.

A long time ago I said I had never seen this.

Recently I made isis.sprintlink.net be a NetBSD-1.2_BETA
box instead of running an ancient copy of BSDI's BSD/386 1.x.

I am happy with the results.

As I said though, I've run into this bug while isis was
running a large number of big processes which had the
characteristics one would expect from systems built on
LISP dialects: they reach out and touch lots of pages all
at once sometimes.  Also, since one of the processes in
question was an emacs, and another was an interactive scsh
process, they would sit waiting for human-driven input for
considerable periods of time.

Creating a bunch of garbage to try to trigger gcing in
scsh and doing interactive stuff with emacs would
(reproducibly, even after reboot, provided enough other
processes were eating memory) reproduce the slowdown.

Looking at vmstat -s showed that there had been numbers of
processes swapped out and in, and this led me to think, 
"I have seen this movie before, in StunOS".   Adjusting
the value of maxslp upwards to 255 has, as with SunOS,
helped enormously.   (In SunOS, this would disable
swapping; in NetBSD this appears to make "a long time"
even longer, letting the swapper go after things that
haven't been active for more than 4 minutes be candidates
for being swapped out).

Unsurprisingly, my paging rate has increased, but the
amount of swapping has dropped to nearly nil, and I have
yet to encounter user-noticeable system-slowdown when
there is a heavy demand for real memory.

	Sean.

-----BEGIN PGP SIGNATURE-----
Version: 2.6.2
Comment: PGP Public Key in ftp://ftp.sprintlink.net/engineer/smd/pgpkey

iQCVAwUBMgxOS0SWYarrFs6xAQH8UAP/QNLu+HrVvaOZ96ndWvNzd5BIpeNtDh9R
w9bvSUwriUw6LK2V1jJpWipIg29+2OI/x52bMZ9JCWTmJ/ygfKG47vInqnTd+Zhm
6BwKRMIQGoxyjoJP9RUsKcpTrf6J5QbiNp48nUt3R99ACAzpUNFHczZGzoBL2bK8
RNjY4UpJv2U=
=iZZ2
-----END PGP SIGNATURE-----