Robert Love [earlier interview] submitted a patch to implement strict VM overcommit on the 2.4-rmap kernel (ported from Alan Cox's 2.4 tree). Describing the patch, Robert says:
"We introduce new overcommit policies that attempt to never succeed an allocation that can not be fulfilled by the backing store and consequently never OOM. This is achieved through strict accounting of the committed address space and a policy to allow/refuse allocations based on that accounting."
From: Robert Love To: linux-kernel Subject: [PATCH] strict VM overcommit Date: 11 Jul 2002 22:28:39 -0700 The attached patch implements strict VM overcommit on top of the rmap VM. The basis for this is Alan Cox's work in 2.4-ac. This is a port of the strict VM overcommit out of 2.4-ac and into the standard kernel with the following changes: - one or two bugfixes (have sent/will send to Alan) - some cleanups, mostly for coding style - I did not bring over the debugging code - new overcommit policy for swapless machines So what is strict VM overcommit? We introduce new overcommit policies that attempt to never succeed an allocation that can not be fulfilled by the backing store and consequently never OOM. This is achieved through strict accounting of the committed address space and a policy to allow/refuse allocations based on that accounting. In the strictest of modes, it should be impossible to allocate more memory than available and impossible to OOM. All memory failures should be pushed down to the allocation routines -- malloc, mmap, etc. The new modes are available via sysctl (same as before). See Documentation/vm/overcommit-accounting for more information. Again, Alan deserves the credit for the design of all this. The patch is against 2.4.19-pre7-rmap13b but should apply to later releases with little trouble. Enjoy, Robert Love
From: Robert Love Subject: [PATCH] strict VM overcommit for stock 2.4 Date: 12 Jul 2002 10:30:39 -0700 A version of Alan's strict VM overcommit for the stock VM is available for 2.4.19-rc1 at: ftp://ftp.kernel.org/pub/linux/kernel/people/rml/vm/strict-overcommit/2.4/vm-strict-overcommit-rml-2.4.19-rc1-1.patch This is the same code I posted yesterday (see "[PATCH] strict VM overcommit for" from 20020711) except for the stock non-rmap VM in 2.4. Hugh Dickins sent me a few fixes, mostly for shmfs accounting, that he recently discovered... that code is not yet merged but will be, probably after this weekend. I still encourage testing and comments. Robert Love
KernelTrap interviews with members of the above thread: