[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC] vmtruncate releases pages of MAP_PRIVATE vma


Hello!

On Tue, Jan 21, 2003 at 11:51:01AM -0800, Andrew Morton wrote:

> > I think vmtruncate() should preserve that pages.
> That would make sense.  But we'd have to go and create zillions
> of copies of pages inside truncate, and given that the behaviour
> is unspecified, it is questionable whether anyone should be
> relying on the behaviour anyway..

It is way too easy to truncate some library and all executables (that are loaded
right now) will go nuts (Just did echo >/lib/libncurses.so.5.2 and expected
everything will get SIGBUS, but all the bashes and mutt went crazy consuming
memory until oom-killer killed them. Kind of surprising behaviour, I'd say.
Test was done on 2.4.19).
Also *BSD systems seems to return -ETXTBSY not only when you try to write-open 
running executables, but also all of shared libs used (and this is probably
even more logical ).

Bye,
    Oleg
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo _at_ vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


この情報があなたの探していたものかどうか選択してください。
yes/まさにこれだ!   no/違うなぁ   part/一部見つかった   try/これで試してみる

あなたが探していた情報はどのようなことか、ご自由に記入下さい。特に「まさにこれだ!」と言う場合は記入をお願いします。
例:「複数のマシンからCATV経由でipmasqueradeを利用してWebを参照したい場合の設定について」
References: