This is on my Framework Laptop:
free -h total used free shared buff/cache available Mem: 58Gi 3,3Gi 47Gi 82Mi 8,6Gi 55Gi
Here is my Proxmox server:
free -h total used free shared buff/cache available Mem: 125Gi 66Gi 33Gi 24Mi 26Gi 58Gi Swap: 8,0Gi 0B 8,0Gi
Meanwhile the electron app you’re trying to run
The other day my laptop was sluggish as hell, checked top and turns out Discord and Orca Slicer were maxing out my cores
Is Orca that resource intensive? I’m running it in a container with KasmVNC and have never really checked out the resource usage. Admittedly it’s on one of my local servers in another room. I guess it’s how large your projects are too.
Edit: maybe it’s just my small projects
And your browser with 300 open tabs doesn’t even fit into the room
Firefox unloads old tabs when restarting the browser, so most of those are more like temporary bookmarks.
Don’t think I’ve ever seen someone open 300 tabs in one session or on Chromium…
i think i have over 200 tabs open in Zen (firefox fork)
you just need more things to run on it
I wish I was a cat
I wish you were a cat too
Gives a lot of Space for running Virtual machines.
Also browsers can chew that up fast if you have a lot of tabs, Firefox has managed to do it a few times. At least until I started limiting its RAM to 8GB (best decision ever)
Limit Firefox to 8GB of RAM .desktop file
[Desktop Entry] Version=1.0 Name=Firefox RAM limit 8GB GenericName=Firefox Ram limit 8GB Comment=Limit RAM for Firefox to 8GB; Exec=systemd-run --user --scope -p MemoryLimit=8G firefox Icon=firefox Type=Application Terminal=false Categories=Utility;Development; StartupWMClass=Firefox
(To use it with other apps like Chrome or Electron apps just replace the command at the end, and startup class with the ones from the program you’d like to run. Icon and Name changes are optional but might be desirable so you remember what app it is for).
Alternatively you can open
about:config
and limit memory usage there. For example limit in-memory cache.EDIT: it seems firefox doesn’t allow to set RAM limits yet, only cache sizes
Something I didn’t consider when answering earlier is that even if Firefox did have good RAM usage limiting built-in I probably still wouldn’t use it or recommend it, because one of Firefox’s biggest problems is that it leaks. And memory leaks will not be negated by Firefox’s built-in RAM limiter but they will be by systemd’s (or anything else you might be using instead) Firefox would still crash in the event of a leak but it’s still better than it taking gnome or other apps with it, or freezing your system entirely.
Does it kill Firefox if it tries to go over the limit? I think I tried this once and if there is a memory leak it just closes itself (which is batter than hogging the whole system, bit still)
No, it just limits the amount of RAM that Firefox (or whatever other application you launch with these parameters) will see.
A few Firefox tabs may crash occasionally as a side effect. And obviously if Firefox eats up all of the 8GB it’s allocated it may crash itself though usually it doesn’t and tabs will crash before the browser crashes.
I’ve seen builds of the Linux kernel that comfortably fits in my on-die CPU caches.
So it would just be a picture of an empty sofa.
% free -h total used free shared buff/cache available Mem: 125Gi 15Gi 90Gi 523Mi 22Gi 110Gi Swap: 63Gi 0B 63Gi
I’ll use it eventually. Just gotta let the disk cache warm up.
63GiB swap, really…?
I have enough disk space.
Plus my
/tmp
is a ramdisk and sometimes I compile large things in there (Firefox) so it is nice to let it be flushed out to disk if there are more important uses for that RAM than holding a file that most likely won’t be read again.I see… but you only use 15GiB… Or are there days you actually use up the memory?
Yes. As this is a workstation the memory use is highly variable, >95% of the time I would probably barely notice having 32GiB. But other times it is a huge performance win to have that capacity available. Sometimes I am compiling lots of stuff and 32 compilers running + ample disk cache is very important. Other times I am processing lots of data and other times I am running a few VMs.
It is a bit of a luxury. I think if I was on a tighter budget I would have gone for 64GiB. However the price difference wasn’t that much and at least a handful of times I have been quite happy to have that capacity available. And worst case I just have everything sitting in disk cache after a warm up which is a small performance win on every small task.
One of the cushions is your browser, the other half some IDE you use to write an one-liner.
the rest is electron
Can’t relate, just upgraded my laptop from 32GB to 64GB since VScode would keep closing due to OOM. What? Oh, no, it’s not vscode’s fault…I keep like 5 Firefox windows with 30+ tabs open, like a fucking maniac… Close them? What do you mean “close” them?
Only 30 tabs, you need to bump those numbers up!
I had around 1500 open tabs in Firefox. It was fine. I figured enough was enough and closed them all. Now I close all tabs at the end of the day before shutting down.
What is “shutting down”?
Wait, do people shut down their computers when they’re done using them?
I know I did on the desktop PC we had at home when I was a kid… But now the desktop doubles as a homeserver (and does that more than it does gaming lately) and the laptop just goes to sleep rather than shutting it down.
i think you might be able to run kde plasma with that!
Fun fact, KDE is very lightweight. More so than a lot of folks give it credit for
plasma wayland just doesn’t work with orca and x11 uses 7× your system resources
Better add 32 GB Zram to be safe tho
I use Kde plasma so I’m allowed to make fun of it
Java would like to hog the couch
That’s how I got a free netbook. The netbook had 32GB flash with windows and office occupying 27+GB. Then windows wanted to do an update - with an 8+GB file. Spot the problem. And windows can get quite annoying with updates. As the netbook could not be expanded, and attempts to redirect the update to a USB stick did not work, a newer netbook was bought, and I got the old one. Linux plus libreoffice plus a bunch of extras happily sat in 4GB…
Wondering how my 64gb will outlast every other part upgrade my gaming Linux box will get over the years
Am i the only one who still has no problems with 8GB? Not that I wouldn’t be happy with more but i can’t remember the last time I’ve even thought about ram usage
If your job requires you to use chrome and vscode, 8GB is usually not enough :/