lkml.org 
[lkml]   [1998]   [Aug]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [discussion] Swap overcommitment recovery
AIX will send the signal SIGDANGER to all processes before actually
killing processes. By default SIGDANGER is ignored.
Processes that have handlers for SIGDANGER are later skipped
when searching for the real victim to kill.

Really, programs which use the standard malloc calls cannot
do much on SIGDANGER but to be nice and exit, or bee bad and
keep all their resources.
With extensions to the malloc library or with a private memory
allocator it is possible to unmap memory pages that are not used
by malloc (AIX has a disclaim() call for that) and free some swap
space. Some garbage collection may be nice too but not always
possible (or fast enough, and garbage collection algorithms may
need more memory just to run).

For Rik's patch:
a. Processes that mmap physical memory
segments may dangerous to kill just like processes that have
direct I/O access. The general trend in hardware design is to
use MMIO.
b. We need an option (per process) that the kernel will allways
commit swap space. Such processes will fail calls to brk, sbrk,
mmap, shmat, shmctl (did I miss anything) if sufficient swap
space cannot be allocated. Such processes will be skipped when
looking for victims to kill. I do not know if that belongs in
the process' personality or elsewhere (does it already exist?)

Itai
--
Itai Nahshon nahshon@actcom.co.il
Also nahshon@vnet.ibm.com

-
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.altern.org/andrebalsa/doc/lkml-faq.html

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