lkml.org 
[lkml]   [1999]   [Sep]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: dynamic swapspace
On Sat, 25 Sep 1999, Enrico Weigelt wrote:

> Date: Sat, 25 Sep 1999 21:24:47 +0000
> From: Enrico Weigelt <weigelt@nibiru.pauls.erfurt.thur.de>
> To: Linux-Kernel list <linux-kernel@vger.rutgers.edu>
> Subject: dynamic swapspace
>
>
> hi all,
>
> i want to write an dynamic swap manager (allocate swapspace when
> needed).

mmm smells like windows to me ;-)

> * let the memory allocation functions block processes which request more
> memory than the free amount.
oke swap let seee this situation

swap deamon needs memory, but there is not enough memory so swap deamon
get blokked. Next there will me no memory so other precesses get locked
to. finaly all processes get bloked and no process responce anymore.

so a reboot is needed ( magic sysrq )

> * add a process flag which tells the memory allocation functions by
> bypass
> the new mechanism - for critical processes like the swap deamon itself.

but there is no memory so the swapdeamon crashes and the fuction will not
work anymore


My idea:

i think the kernel thread/deamon is the best you can do when you
really need this function but the you should rewrite the function which
checks if there is enough memory ( call is malloc ) if not so then
activate the swapdeamon/thread so more memory will be available if the
swapdeamon/thread fails than the malloc fails and you get the normal
result.

an other think you should think about is when the dealloc call makes
memory free it should return some swap, e.g. when more that 100 mb swap
is free then deswapalloc [ what a word ;-))) ] until there is about 50 mb
memory free.

also a problem is the place where the swapfile will be placed or grown
because if got about 13 partitions in my linux filesystem and where should
the swap be placed/grown because not every partition is suitable for this
sort of actions.


oke that where my 0.10 cents

--
Robbert Muller

mjrider@writeme dot com | Never let a luser on your console.
uin: 9659330 | Because that means they're in your room.



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

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