Is it the case that default Ubuntu installs are set up with a RAM/swap configuration such that you can just... run out? Like a lot? My last three installs have been set up this way and I don't understand it
Don't recommend running out of memory, personally
I remember around 11 or 12 years ago, the best practices for desktops went from "have 4x as much swap as ram" to "have 0.5x as much swap", corresponding I think to the sudden wide availability of large (1G+) flash produced by the campaign to use USB thumbdrives for swap on Vista (which was otherwise unusable on most machines). At the time, overuse of flash as swap would lead to drives quickly overrunning max writes.
In business contexts like servers, swap was already small.
The idea (as explained to me in 2011 or 2012) was that swap should only exist for emergencies on servers, bc if you have a lot you can get used to running in low ram conditions & having horribly slow response times.
That said, i've only run out of memory on ubuntu as a result of severe memory leaks in lightdm & some window managers -- leaks that seem to manifest as a function of number of windows created.
@enkiv2 I've definitely run out in lower RAM setups because I went overboard, but I'm not sure why it's happened in my current setup (hard to debug when you're totally out of memory)
The display manager memory leaks have gotten progressively worse in the past ~6 years; i recommend keeping an eye on a running htop with sort order set to memory usage.
Browsers have gotten way worse about their footprint too & they all leak.
If you can read the whole thread, we did some troubleshooting and I found some virtual memory settings that helped, but it was vodoo for me.
@xor today I killed my work GMail tab, which was eating 2.5Gi of memory, in order to load the Q3 H-1B wages spreadsheet in LibreOffice, which consumed about 2Gi of memory
@xor This is not that much problematic since 18.04 when they switched to swapfiles from swap partitions. It is easy to add new swapfiles on the fly.
@xor there's definitely a school of thought that says swap is bad, don't configure swap. Made more sense on spinning rust where you can easily crush the entire system into multi minute swapstorms if you're not careful.
I think my 18.04 laptop install didn't have any swap, I added a swapfile at 1x ram and am pretty happy with the situation
@xor i don't actually know what ubuntu does by default these days, but there's been a trend for various reasons (i think: average available RAM has gone up a lot, swapping tends to chew up SSDs) away from recommending the use of swap in general, so that might be a factor.
@brennen I get that, but like... are people supposed to just fully do manual memory management? Is something supposed to kick in that I'm missing? I find myself constantly running top and free
> just fully do manual memory management?
generally i don't think so, but how much RAM are you working with?
(in the last couple of years this is a problem i've only really had to deal with on purpose-specific VMs, and generally there if something's swapping i feel like i need a bigger VM. i haven't tried to run like a full desktop browser session full of modern (read: massively resource-intensive) web apps on anything with less than like 8 gigs of RAM in a while, though...)
@xor i just checked the one ubuntu machine i have (18.04, installed with the recommended partition scheme as best i remember) and it's got a gig of swap partition for a 16 gig system, so maybe you _do_ need to add some swap above their defaults for a system with less RAM and a heavy workload.
disclaimer: there's a very good chance i'm missing something here.
@brennen that's what I'm working with too! and it's weird!
@xor history too hard to change cause shitty to test
@xor Ubuntu also Canonical setzt mir zu viel auf Snaps und ich hoffe das meine Debian Mutter diesen ganzen Schwachsinn nicht mit geht. Daher weiß ich schon warum ich bei Debian bleibe und auch viele in Deutschland. Kein Interesse an Unbuntu und dem Wahnsinn den Sie betreiben. Ich hoffe die Menschen wenden sich ab von Ubuntu das Sie wieder auf Kurs kommen. Denn sonst ist das bald das zweite Windows unter Linux
@xor Ubuntu so Canonical relies too much on Snaps and I hope that my Debian mother won't go along with all this nonsense. So I already know why I'm staying with Debian and many in Germany. No interest in Unbuntu and the madness you run. I hope people turn away from Ubuntu and get you back on track. Otherwise it will soon be the second Windows under Linux
@xor somebody said recently something like "imagine if we managed CPU like we manage memory, you ask for a block of compute and are given no indication of whether that's a lot or a little but if you ask for too much then you're killed for being greedy"
@xor does ubuntu default to using ZRAM yet? Also, what RAM config do you have that runs out? Even with 4GB I've not really run into swap issues on my pinebook pro, but I suppose I am using Debian.
The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!