lkml.org 
[lkml]   [2001]   [Jul]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.4.x swap >= 2*memsize requirement status.
On Sat, Jul 14, 2001 at 01:42:46PM +0200, J.R. de Jong wrote:
> Can anyone shed some
> light on how 'required' this requirement really is and what one could
> expect to happen when this requirement is not met?

Well, I just swapoffed my swap partitions and I am still able to compose this
email, so I guess its not actually required. I'm even building mozilla at
the same time. Ill have to add the swap back before the mozilla build gets
to the final link stage :-) I believe that the issue is that with 2.4 once
a process gets pages swapped out, it owns that area of swap until the process
dies. The 2.2 kernel would free the swap space up when it swapped the
processes pages back into memory. The 2.4 way performs much better than the
2.2 way. The problem is that if the swap space is less than the ram size, it
is possible to fill up the swap and then strange things happen. For example
consider a machine with 64M of ram and 64M of swap which is running 2 32M
processes. Now lets say we start a third process that grows to a large value
and causes both of the original 32M processes to be swapped out. Now the
third process dies a the two 32M process can run in memory again, but they
still own the swap space they were swapped into. This means that when we
start a third process, it can not be swapped out since the swap space is
owned the the two original processes, they will get swapped out instead when
memory gets tight.

I know that people have worked on changing this behavior, but I do not know
what the current state of those changes is.

Hope this helps,

Jim
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:57    [W:0.056 / U:0.120 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site