Sujet : Re: Linux doesn't seem to manage memory very well
De : not (at) *nospam* telling.you.invalid (Computer Nerd Kev)
Groupes : comp.os.linux.miscDate : 04. May 2024, 01:13:26
Autres entêtes
Organisation : Ausics - https://newsgroups.ausics.net
Message-ID : <66357da6@news.ausics.net>
References : 1 2 3 4 5 6 7 8
User-Agent : tin/2.0.1-20111224 ("Achenvoir") (UNIX) (Linux/2.4.31 (i586))
Carlos E.R. <
robin_listas@es.invalid> wrote:
On 2024-05-03 01:23, Computer Nerd Kev wrote:
The OP has noted now that the process that consumes their RAM is
Chrome or Firefox. I've not seen a detailed description of why it
happens, but I've long noted that Firefox seems to expand its RAM
usage to the available space, but different from a memory leak in
that it usually leaves a certain amount free. I assume that this
in intended behaviour. I run current Firefox on a PC with 2GB RAM
and I don't have it getting killed by the kernel, nor do I have
problems with kernel crashes/reboots. I've also tried running
recent Firefox on a PC with 512MB RAM and noticed that it performs
much worse than with 2GB RAM, slowing down to a crawl while loading
some websites, suggesting that it really does need more RAM in that
case.
Firefox uses a lot of memory.
One problem is memory fragmentation. It reserves many chunks then
eventually frees many, but they may not being contiguous, so maybe they
can not be reused, so it requests more memory.
It seems to me like it looks at the available RAM (not including
swap space) and only works at freeing space when the free RAM
remaining gets to a certain size/percentage. Increading RAM because
one feels there isn't enough space free therefore isn't really a
solution because Firefox will eventually expand to fill that new
space too. Although if it tries to leave a minimum percentage free,
the size of that minimum would increase.
But it would be great to see an explanation of how it really works
from one of the Firefox developers (one can dream).
When I started using Linux, back in 1998, I did notice that Linux needed
more memory than Windows to work right.
It did compared to mid-90s Windows. With XP and later the
difference switched the other way and it surprises me how much more
RAM Windows 10 can use doing nothing compared to ~100MB used after
modern Linux boots up with to a lightweight desktop. Older Linux
used much RAM less than that, but still more than a basic Win98
installation (the old PC I'm posting from with 80MB RAM dual-boots
to either).
I had to improve my hardware
because of that. My previous computer had 8 GB and it was not enough, it
was swapping. So now I have a machine with 64.
I wouldn't know what to do with 8GB (well I know some people like
to run lots of VMs, but that's too much to think about in my
opinion).
I don't use web browsers to play video.
No youtube? :-)
Only with youtube-dl (yes I know there's also the yt-dlp fork). To
find videos there I also avoid their Javascript-filled website and
use Invidious as well as "site:youtube.com" in DuckDuckGo.
-- __ __#_ < |\| |< _#