Description of problem:
I'm a designer and Inkscape is my primary design tool. Recently it has started to silently disappear - I'll be using it, and the an Inkscape window will just close. Running it from the command line doesn't show any errors, nor do I get crash reports.
It happened again today, and I found this in the journal:
[20761.893754] systemd-oomd: Killed /firstname.lastname@example.org/app.slice/app-flatpak-org.inkscape.Inkscape-10790.scope due to memory used (16483962880) / total (16652419072) and swap used (7745417216) / total (8589>
[20761.978898] systemd: app-flatpak-org.inkscape.Inkscape-10790.scope: systemd-oomd killed 21 process(es) in this unit.
[20763.076267] systemd: app-flatpak-org.inkscape.Inkscape-10790.scope: Consumed 20min 56.008s CPU time.
The issue currently occurs multiple times a day for me. I've noticed similar behaviour with Firefox, but with a lower frequency and I haven't confirmed that it's oomd that's responsible.
Version-Release number of selected component (if applicable): systemd-248.4-1.fc34.src.rpm
How reproducible: happens multiple times a day, but the precise circumstances aren't clear.
Steps to Reproduce:
1. Have a bunch of memory intensive apps open - lots of browser tabs, maybe a VM running
2. Open multiple large SVGs in Inkscape, edit, export, etc
You've used up 99% of available system memory and 90% of swap (assuming 8 GB total swap, the number is cut off but that's probably right). Killing something is the right thing to do because your system is very very close to thrashing and becoming unresponsive. (I guess you're using zram, because if not I would expect it to already be unresponsive with so much swap used.) Having systemd-oomd preemptively kill your application before the system becomes unresponsive was a design decision to prioritize maintaining desktop responsiveness. We know that if we don't kill *before* your desktop becomes unresponsive, you're probably going to have to either power off to regain control, or wait 30+ minutes before mouse and keyboard input start to work again. So killing one of your applications using the most memory is desirable to keep your desktop working.
Importantly, once it gets to this point, there's no time to prompt the user or ask the user what to kill. A kill has to come immediately. If we want to introduce some way to prompt the user to decide which application to close, that needs to happen earlier, before memory use reaches this critical threshold.
The biggest problem here is that you have not received any notification why inkscape disappeared. systemd knows how to use D-Bus, so it should be able to send a desktop notification to tell you what it has killed.
OK, let's close this.
Regularly killing an app with no feedback seems like a Very Bad Thing to me, but let's take that up elsewhere.