Re: Some questions about linux kernel.

From: Peter Zaitsev (pz@spylog.ru)
Date: Sun Mar 12 2000 - 02:20:57 EST


>
> It's not so. SOME solution is easy enough. But is it right solution ?
> This is unclear. To many peoples ANY solution where ANY process can
> be killed is "not right" -- theonly proper solution will be one where
> you'll get NULL from malloc when there are not enough memory.

HM. Does not malloc return NULL if it's out of memory now ?

>
> RR> The problem has been that people don't understand the issues involved
> RR> and start a flamewar as soon as a patch (re)surfaces.
>
> Exactly.
>
> RR> Also, making a solution that everybody agrees with seems
> RR> to be impossible in this situation :)
>
> Ideal solution will be: solution where
> 1) processes will be NEVER killed.
> 2) if there are not enough memory malloc just return NULL.
> 3) virtual memory is used effectively (that is almost 100% of
memory+swap
> can be used for "real data").
>
> AFAIK you can more or less satisfy any two items but not all three at
once...

Well. Malloc of couse has to return null if there is no more memory left.
The problem is if the memory will be out and so no process will be able to
allocate memory the system will not halt but will become unusable as even to
login you need memory.
At list the thing should be done I think is the memory reserved for root
usage only. So we'll have a possibility to at least login and kill bad task.

-
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/



This archive was generated by hypermail 2b29 : Wed Mar 15 2000 - 21:00:21 EST