On Friday, December 6, 2019 10:05:42 AM MST Przemek Klosowski via devel wrote:
Many systems have 8, 16 or even 32GB of RAM now. Mine has 16GB, and
and
I regularly run out of memory because some Chrome tab is open to a
website that keeps reloading ads and leaking memory, sometimes consuming
gigabytes per tab.
I could only suggest not to use proprietary software, such as Chrome.
The disk speed being in the double digit MB/s, swapping multiple GB
takes minutes. During this time, the system is unresponsive,
unfortunately---the mouse is frozen, alt-tab does not switch between
apps, etc. Sometimes I can flip to a text console and kill chrome, but
most of the time the only remedy is to wait it out or force reboot. I am
not sure if the freezing is mostly kernel's fault or the display
subsystem's fault.
For that reason, I don't believe that the old advice of swap = 2*RAM is
relevant today. Even 1*RAM is of questionable utility---the main reason
for 1*RAM guideline is the ability to hibernate to swap, in my opinion.
Instead, I'd say that with the RAM prices being what they are, everyone
should try to buy as much RAM as appropriate for their regular use.
That's not really an option for many users, such as myself. For example, the
maximum amount of memory one could install in the system that I'm using to
type this message on is 8 GiB. That is, a maximum of two slots of 4 GiB.
I'd rather just not use software that constantly leaks memory, and so I don't
use web browsers often, but I use either Falkon or Firefox when I do need a
web browser. This probably wouldn't work for most people, as it's common for
folks to prefer to do everything in web browsers these days, and I get that.
To each their own. I still build my systems with 1*RAM, and set the swappiness
as appropriate. It seems to work out well for me, and so I can only recommend
that others give it a try, to see if it works for them.
--
John M. Harris, Jr.
Splentity