Re: oom-killer vs system not reachable

From: Sam Watkins (swatkins_at_fastmail.fm)
Date: 12/17/04

  • Next message: Sam Watkins: "Re: Server Security"
    Date: Fri, 17 Dec 2004 15:39:49 +1100
    To: debian-user@lists.debian.org
    
    

    On Sun, Dec 19, 2004 at 10:28:28AM +0100, Robert Ian Smit wrote:
    > The points concerning the mbox file are taken (in fact I knew as
    > much). Do you think that Linux might stop to respond or get stuck
    > for a while as a result of the big file.

    One problem would be when mutt rewrites the file on exit (or pressing
    $), that is a lot of IO to do. On linux 2.4 at least if one process is
    using a lot of IO, the other processes seem to grind to a halt. I think
    they are fixing this in 2.6. Perhaps you could try upgrading to 2.6 if
    you're using 2.4?

    > In other words would the symptoms of an oom-killer event and the
    > resource shortage before it be noticable for a longer period?

    As I understand, there's two ways the computer can run out of vm -
    first, if the system is pretty idle, and one process quickly allocates a
    large amount of memory which goes over the limit, that process will be
    killed, and probably no other programs will die. This is relatively
    painless.

    Another situation is that several processes are competing for memory,
    cpu and io, and you don't have enough ram to hold all the active pages
    in ram at once. Then the system "thrashes", constantly swapping.
    If your active set expands gradually and more, the system gets very very
    slow. If it is on its way to running out of memory, it could take a
    long time before the memory-hog processes are killed, and other
    "innocent" processes might quite likely be slain into the bargain.

    The weirdest thing I saw with swapping was once, trying to install red
    hat on a relatively small machine, and its graphical installer used up
    all the ram, and swap wasn't set up yet, so the only thing it could do
    to free more ram was to "swap out" the executables back to the cd-rom,
    so the thing was actually thrashing on the CD-rom, it was most unusable!

    Anyway, I think the best way to find out what is happening on your box
    is to monitor or log what happens when the system dies like this, either
    watch it with top, or monitor maybe with something like:

    mkdir -p /tmp/death.log
            while true; do
            D=`date +%Y%m%d.%H%M%S`
            ( w; echo; free; echo; ps auxf; ) > /tmp/death.log/$D
            sleep 15
    done

    -- 
    To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org 
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
    

  • Next message: Sam Watkins: "Re: Server Security"

    Relevant Pages

    • Re: How to set up a Linux machine that occupies the minimum memory footprint ?
      ... Of course, if you use 8GB of RAM, or more precisely if you ... Are you saying that if I have a 4GB RAM memory, ... Linux will somehow "know" that it doesn't have ... You've said in another message that your app is ...
      (comp.os.linux.setup)
    • Re: How to set up a Linux machine that occupies the minimum memory footprint ?
      ... Of course, if you use 8GB of RAM, or more precisely if you ... Are you saying that if I have a 4GB RAM memory, ... Linux will somehow "know" that it doesn't have ... You've said in another message that your app is ...
      (comp.os.linux.misc)
    • Re: Just the CP/M file system
      ... - Or a 1K monitor with basic memory ... emulator which allows you to single-step not only through RAM, ... the memory test and loop read/write for hardware diagnostics. ... A properly implemented file system in NAND flash will also ...
      (comp.os.cpm)
    • Re: OT (slightly) swap limits
      ... influence your decision on how much swap was enough. ... processes due to lack of memory. ... I've run machines with 1Gig or more RAM with NO SWAP. ... Linux possible when before on Unix it wasn't? ...
      (Debian-User)
    • Re: "Insufficient virtual memory" error message in Linux
      ... My problem is that if I tell the program to use more than 2 GB of ram the program eventually crashes with a message "insufficient virtual memory". ... I am still trying to understand if this issue arises because of an intrinsic limit of the CPU, of linux or of the compiler. ...
      (comp.lang.fortran)