3 ms·
More vfs cache for swap space is not a trade off here, but rather a mostly incorrect oversimplification. The value of more cache is very non linear, it depends
by zzzcpan 7y ago
More vfs cache for swap space is not a trade off here, but rather a mostly incorrect oversimplification. The value of more cache is very non linear, it depends on the workload and usually only matters when nearly all of the disk I/O is already exhausted, the exact situation you want to prevent by using more of the same disk I/O for swap. Essentially trading more cache for abrupt performance degradation in terms of latency and responsiveness. I mean, sure, if you can't use zram, say you are on a system that's a bit behind on performance features, like freebsd, very light swappiness might be ok, might free up some of very unused memory and just not be aggressive enough to swap something that causes latency, responsiveness problems, although this is not certain. With memory compression you can swap and compress much more of it more aggressively and be certain that no abrupt performance degradation can happen. It feels like having more ram that's gradually affecting tail latency the more you use it.
- Dylan16807 7y agoZram is nice when you're barely using it, but every time I've seen it get low on memory it degrades quite abruptly, much worse than ssd swap.