lkml.org 
[lkml]   [1996]   [Dec]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: memory limits broken !!!
From
Date
Gerd Knorr <kraxel@cs.tu-berlin.de> writes:
> Played around with the latest wine today. And wine it managed to crash the
> box by eating up all memory.
[...]
> felix kraxel ~# ulimit -a
> core file size (blocks) unlimited
> data seg size (kbytes) 1024
> file size (blocks) 1024
> max memory size (kbytes) 1024
> stack size (kbytes) 1024
> cpu time (seconds) unlimited
> max user processes 256
> pipe size (512 bytes) 8
> open files 256
> virtual memory (kbytes) 2048
[...]
> Had a top running in another xterm and could watch wine eat memory.
> Stopped wine with ^C at the 40MB-mark (with 1 MB limit !!!) to avoid
> another crash (I have 16 MB RAM and 40 MB swap). This should'nt happen,
> should it ?

Unfortunately, the data seg limit only applies to memory obtained from
brk(2). Wine uses mmap(2) to obtain most of its memory (AFAIK). This
should be limited with RLIMIT_AS (virtual memory). Unfortunately, this
limit is not enforced by Linux 2.0.24.
If the address space would be limited, you could not have started
Wine: It probably uses more than 2MB address space even before main()
is called...

Regards,
Martin

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