RAM difference after using firefox


tumbleweed KDE user over here stalked by a little problem

when booting up RAM usage is about 600mb.

After starting firefox RAM goes up.
When closing firefox the RAM usage stays higher than at the start up, about 750mb.

how come?
shouldn´t the usage go down to its initial value(600mb)?

Network Buffers and routing tables don’t shrink they grow. Firefox called for them, the Kernel sees the need and allocates them. Since others might need them - they don’t go away for a while sometimes not til the next boot.
Cron jobs also run while Firefox is up - PackKit also uses network resources (the thing that says updates are available) is call by systemd timers.

Run top and iotop to see what happens when Firefox starts.

Probably pages are kept in memory. When you start Firefox again, it will startup faster, because the code pages are still there (the startup time difference will of course depend on how fast your mass storage is, e.g. SSD vs. revolving disk).

And that is of course not restricted to Firefox.

I assume you mean “next shutdown”. I doubt they will be in use by a not running system. lol!

It also caches the info in memory for later use, what you need to do for example it run free before and after;

free -h
               total        used        free      shared  buff/cache   available
Mem:            62Gi       3.5Gi        48Gi        88Mi        10Gi        58Gi
Swap:          3.6Gi          0B       3.6Gi

echo 3 > /proc/sys/vm/drop_caches

free -h
               total        used        free      shared  buff/cache   available
Mem:            62Gi       2.8Gi        58Gi        88Mi       1.0Gi        59Gi
Swap:          3.6Gi          0B       3.6Gi