public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: LA Walsh <law@sgi.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Break 2.4 VM in five easy steps
Date: Thu, 07 Jun 2001 13:47:25 -0700	[thread overview]
Message-ID: <3B1FE85D.F7BE88F4@sgi.com> (raw)
In-Reply-To: <3B1E4CD0.D16F58A8@illusionary.com> <3b204fe5.4014698@mail.mbay.net> <3B1E5316.F4B10172@illusionary.com> <m1wv6p5uqp.fsf@frodo.biederman.org> <3B1EA748.6B9C1194@sgi.com> <m1g0dc6blz.fsf@frodo.biederman.org> <3B1F9CEC.928C8E66@sgi.com> <m1ofs044xc.fsf@frodo.biederman.org>

"Eric W. Biederman" wrote:

> LA Walsh <law@sgi.com> writes:
>
> >     Now for whatever reason, since 2.4, I consistently use at least
> > a few Mb of swap -- stands at 5Meg now.  Weird -- but I notice things
> > like nscd running 7 copies that take 72M.  Seems like overkill for
> > a laptop.
>
> So the question becomes why you are seeing an increased swap usage.
> Currently there are two canidates in the 2.4.x code path.
>
> 1) Delayed swap deallocation, when a program exits after it
>    has gone into swap it's swap usage is not freed. Ouch.

---
    Double ouch.  Swap is backing a non-existent program?

>
>
> 2) Increased tenacity of swap caching.  In particular in 2.2.x if a page
>    that was in the swap cache was written to the the page in the swap
>    space would be removed.  In 2.4.x the location in swap space is
>    retained with the goal of getting more efficient swap-ins.

----
    But if the page in memory is 'dirty', you can't be efficient with swapping
*in* the page.  The page on disk is invalid and should be released, or am I
missing something?

> Neither of the known canidates from increasing the swap load applies
> when you aren't swapping in the first place.  They may aggrevate the
> usage of swap when you are already swapping but they do not cause
> swapping themselves.  This is why the intial recommendation for
> increased swap space size was made.  If you are swapping we will use
> more swap.
>
> However what pushes your laptop over the edge into swapping is an
> entirely different question.  And probably what should be solved.

----
    On my laptop, it is insignificant and to my knowledge has no measurable
impact.  It seems like there is always 3-5 Meg used in swap no matter what's
running (or not) on the system.

> >     I think that is the point -- it was supported in 2.2, it is, IMO,
> > a serious regression that it is not supported in 2.4.
>
> The problem with this general line of arguing is that it lumps a whole
> bunch of real issues/regressions into one over all perception.  Since
> there are multiple reasons people are seeing problems, they need to be
> tracked down with specifics.

---
    Uhhh, yeah, sorta -- it's addressing the statement that a "new requirement of
2.4 is to have double the swap space".  If everyone agrees that's a problem, then
yes, we can go into specifics of what is causing or contributing to the problem.
It's getting past the attitude of some people that 2xMem for swap is somehow
'normal and acceptable -- deal with it".  In my case, seems like 10Mb of swap would
be all that would generally be used (I don't think I've ever seen swap usage over 7Mb)
on a 512M system.  To be told "oh, your wrong, you *should* have 1Gig or you are
operating in an 'unsupported' or non-standard configuration".  I find that very
user-unfriendly.


>
> The swapoff case comes down to dead swap pages in the swap cache.
> Which greatly increases the number of swap pages slows the system
> down, but since these pages are trivial to free we don't generate any
> I/O so don't wait for I/O and thus never enter the scheduler.  Making
> nothing else in the system runnable.

---
    I haven't ever *noticed* this on my machine but that could be
because there isn't much in swap to begin with?  Could be I was
just blissfully ignorant of the time it took to do a swapoff.
Hmmm....let's see...  Just tried it.  I didn't get a total lock up,
but cursor movement was definitely jerky:
> time sudo swapoff -a

real    0m10.577s
user    0m0.000s
sys     0m9.430s

Looking at vmstat, the needed space was taken mostly out of the
page cache (86M->81.8M) and about 700K each out of free and buff.


> Your case is significantly different.  I don't know if you are seeing
> any issues with swapping at all.  With a 5M usage it may simply be
> totally unused pages being pushed out to the swap space.

---
    Probably -- I guess the page cache and disk buffers put enough pressure to
push some things off to swap.

-linda
--
The above thoughts and       | They may have nothing to do with
writings are my own.         | the opinions of my employer. :-)
L A Walsh                    | Senior MTS, Trust Tech, Core Linux, SGI
law@sgi.com                  | Voice: (650) 933-5338



  reply	other threads:[~2001-06-07 20:50 UTC|newest]

Thread overview: 112+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-06 15:31 Break 2.4 VM in five easy steps Derek Glidden
2001-06-06 15:46 ` John Alvord
2001-06-06 15:58   ` Derek Glidden
2001-06-06 18:27     ` Eric W. Biederman
2001-06-06 18:47       ` Derek Glidden
2001-06-06 18:52         ` Eric W. Biederman
2001-06-06 19:06           ` Mike Galbraith
2001-06-06 19:28             ` Eric W. Biederman
2001-06-07  4:32               ` Mike Galbraith
2001-06-07  6:38                 ` Eric W. Biederman
2001-06-07  7:28                   ` Mike Galbraith
2001-06-07  7:59                     ` Eric W. Biederman
2001-06-07  8:15                       ` Mike Galbraith
2001-06-07 17:10                 ` Marcelo Tosatti
2001-06-07 17:43                   ` Please test: workaround to help swapoff behaviour Marcelo Tosatti
2001-06-06 19:28           ` Break 2.4 VM in five easy steps Derek Glidden
2001-06-09  7:55           ` Rik van Riel
2001-06-06 20:43       ` Daniel Phillips
2001-06-06 21:57       ` LA Walsh
2001-06-07  6:35         ` Eric W. Biederman
2001-06-07 15:25           ` LA Walsh
2001-06-07 16:42             ` Eric W. Biederman
2001-06-07 20:47               ` LA Walsh [this message]
2001-06-08 19:38                 ` Pavel Machek
2001-06-09  7:34     ` Rik van Riel
2001-06-06 21:30 ` Alan Cox
2001-06-06 21:57   ` Derek Glidden
2001-06-09  8:09     ` Rik van Riel
  -- strict thread matches above, loose matches on Subject: below --
2001-06-10 22:04 Rob Landley
2001-06-07 14:22 Bulent Abali
2001-06-07 15:38 ` Mike Galbraith
2001-06-07 10:46 Bernd Jendrissek
     [not found] ` <20010607153835.T14203@jessica>
2001-06-08  7:37   ` Bernd Jendrissek
2001-06-08 19:32 ` Pavel Machek
2001-06-11 12:06   ` Maciej Zenczykowski
2001-06-11 19:04     ` Rik van Riel
2001-06-12  7:46       ` Bernd Jendrissek
2001-06-05 22:19 Derek Glidden
2001-06-05 23:38 ` Jeffrey W. Baker
2001-06-06  1:42   ` Russell Leighton
2001-06-06  7:14     ` Sean Hunter
2001-06-06  7:47     ` Jonathan Morton
2001-06-06  2:16   ` Andrew Morton
2001-06-06  3:19     ` Derek Glidden
2001-06-06  8:19       ` Xavier Bestel
2001-06-06  8:54         ` Sean Hunter
2001-06-06  9:16           ` Xavier Bestel
2001-06-06  9:25             ` Sean Hunter
2001-06-06 10:04             ` Jonathan Morton
2001-06-06  9:57           ` Dr S.M. Huen
2001-06-06 10:06             ` DBs (ML)
2001-06-06 10:08             ` Vivek Dasmohapatra
2001-06-06 10:19               ` Lauri Tischler
2001-06-06 10:22             ` Sean Hunter
2001-06-06 10:48               ` Alexander Viro
2001-06-06 16:58                 ` dean gaudet
2001-06-06 17:10                 ` Remi Turk
2001-06-06 22:44                 ` Kai Henningsen
2001-06-09  7:17               ` Rik van Riel
2001-06-06 16:47             ` dean gaudet
2001-06-06 17:17             ` Kurt Roeckx
2001-06-06 18:35               ` Dr S.M. Huen
2001-06-06 18:40                 ` Mark Salisbury
2001-06-06 19:11             ` android
2001-06-07  0:27               ` Mike A. Harris
2001-06-07  0:20             ` Mike A. Harris
2001-06-09  8:16               ` Rik van Riel
2001-06-09  8:57                 ` Mike A. Harris
2001-06-07 21:31             ` Shane Nay
2001-06-07 20:00               ` Marcelo Tosatti
2001-06-07 21:55                 ` Shane Nay
2001-06-07 20:29                   ` Marcelo Tosatti
2001-06-06 11:16           ` Daniel Phillips
2001-06-06 15:28             ` Richard Gooch
2001-06-06 15:42               ` Christian Bornträger
2001-06-06 17:14               ` Ben Greear
2001-06-06 12:07           ` Jonathan Morton
2001-06-06 13:58           ` Gerhard Mack
2001-06-08  4:56             ` C. Martins
2001-06-06 14:41         ` Derek Glidden
2001-06-06 20:29         ` José Luis Domingo López
2001-06-06 14:16       ` Disconnect
     [not found]       ` <3B1DEAC7.43DEFA1C@idb.hist.no>
2001-06-06 14:51         ` Derek Glidden
2001-06-06 21:34           ` Alan Cox
2001-06-09  8:07             ` Rik van Riel
2001-06-07  7:23           ` Helge Hafting
2001-06-07 16:56             ` Eric W. Biederman
2001-06-07 20:24             ` José Luis Domingo López
2001-06-06  4:03     ` Jeffrey W. Baker
2001-06-06 13:32     ` Eric W. Biederman
2001-06-06 14:41     ` Marc Heckmann
2001-06-06 14:51     ` Hugh Dickins
2001-06-06 13:08   ` Eric W. Biederman
2001-06-06 16:48     ` Jeffrey W. Baker
     [not found] ` <m2lmn61ceb.fsf@sympatico.ca>
2001-06-06 14:37   ` Derek Glidden
2001-06-07  0:34     ` Mike A. Harris
2001-06-07  3:13       ` Miles Lane
2001-06-07 15:49         ` Derek Glidden
2001-06-07 19:06           ` Miles Lane
2001-06-09  5:57         ` Mike A. Harris
2001-06-06 18:59 ` Mike Galbraith
2001-06-06 19:39   ` Derek Glidden
2001-06-06 20:47 ` Linus Torvalds
2001-06-07  7:42   ` Eric W. Biederman
2001-06-07  8:11     ` Linus Torvalds
2001-06-07  8:54       ` Eric W. Biederman
2001-06-06 21:39 ` android
2001-06-06 22:08 ` Jonathan Morton
2001-06-06 22:27 ` android
2001-06-06 22:33   ` Antoine
2001-06-06 22:38   ` Robert Love
2001-06-06 22:40 ` Jonathan Morton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3B1FE85D.F7BE88F4@sgi.com \
    --to=law@sgi.com \
    --cc=ebiederm@xmission.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox