How to optimize a RAM-only (swapless) system?
coolaj86 at gmail.com
Tue Dec 21 10:35:49 MST 2010
The bugs I've already been bitten by is that if you have no swap the kernel
will default to sending the oom (out-of-memory) killer on any random process
and kill it in a fashion that to the casual observer appears to be a
segfault (a segfault that nor gdb nor the powers of above will tell you
isn't a segfault at all - only the kernel log).
/etc/sysctl.conf must be configured like so for a system with no swap:
vm.overcommit_memory = 2
vm.overcommit_ratio = 100
I also found that /dev/shm has a memory leak in a few different versions of
the kernel that are particularly profound if continuously writing and
unlinking files there.
I'm looking for a list of other settings sysctl and otherwise - that will
prevent me from banging my head against the wall.
More information about the PLUG