|
|
|
|
|
by edwintorok
4373 days ago
|
|
Except thats not what causes problems in practice.
You get problems with swap when your working set size exceeds your RAM. You'll always be hitting the disk as long as the offending application keeps using too much memory, and it slows down the entire system not just that one application.
When you try to SSH in/log in that requires reading files from disk (or swapping things back in) which can take quite a while due the backlog caused by swapping. If you ran out of memory and malloc returned NULL that would be better, however a lot of applications rely on overcommit so there is no good answer: * you can run with RAM + as much swap to make all applications happy and overcommit off, and accept the long
delays caused by swapping * run with just RAM, overcommit on and no swap, and accept that your applications may be killed by the OOM killer anytime |
|
This is independent of applications whose working set size exceed that of physical memory.