Wednesday, March 06, 2013

Nobody is gonna stop Andrew Morton from singing "la la la"

I'm gonna stick my fingers in my ears and sing "la la la" until people tell me "I set swappiness to zero and it didn't do what I wanted it to do".

https://lwn.net/Articles/83593/

swappiness==0 doesn't mean swap is turned off. If you want to turn off swap, remove swap partition / file. When you don't have swap partition / file, the value of swappiness doesn't matter any more.

Luckily, the misleading swappiness==0 will be changed soon.

... with current reclaim implementation, the kernel may swap out even if we set swappiness=0 and there is pagecache in RAM.
This patch changes the behavior with swappiness==0. If we set swappiness==0, the kernel does not swap out completely ...

http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=fe35004fbf9eaf67482b074a2e032abb9c89b1dd;hp=c50ac050811d6485616a193eb0f37bfbd191cc89

Andrew, soon you can stick your fingers in your ears and sing "la la la" forever, as no one will tell you "I set swappiness to zero and it didn't do what I wanted it to do".