For the past year or so I've been running on this issue on my desktop PC and now on my laptop, where it will freeze or hang really heavily, and It happened in a few distros and two different computers using Fedora with cinnamon , Linux Mint and Kubuntu.
I generally keep the computer running for daily use, with all the stuff opened, IDE's, database managers, shells and specially browsers (with lots of tabs) ... I know my usage is pretty heavy on memory, but I have 12gb on the laptop and 16gb on the desktop, it shouldn't just freeze and become unusable in the middle of the day.
I installed oompd, which helps to recover without rebooting, but doesn't really solve the issue.
Any suggestions on how can I fix or at least debug this are welcome.
It seems odd that a similar freeze condition should occur on two separate computers in a number of different installed distros on those machines.
The reference to "oompd" appears to refer to the systemd-oomd.service, so it sounds like you have enabled that service to monitor the out-of-memory situation, and it's helped, so it sounds like it's a memory problem.
It's worth checking the memory health by running: memtest86+, either by installing it and then selecting it to run at the menu in the next boot, or, or by running it from a live disk on an unmounted system.
An initial way of checking what's using the memory is to watch, or log, the output of a command that shows memory usage over a period of time to see whether any program that is in use is increasing its usage unexpectedly, which may suggest a memory leak. Something like:
Code:
[flip@flop ~]$ ps -eo pid,user,cmd,%mem,rss --sort=-%mem | head
PID USER CMD %MEM RSS
1532 flip firefox 7.9 644192
7816 flip librewolf 5.5 447084
44491 flip firefox 2.8 233552
2182 flip firefox 2.8 231640
7999 flip wolflibre 2.6 213836
106821 flip firefox 2.2 185668
85376 flip firefox 2.2 181712
96603 flip wolflibr 2.1 173576
105987 flip firefox 2.1 173228
This outputs the top 10 users of memory, with the usage in the RSS column in kilobytes in this case on a machine with 8 gigs of RAM.
For a greater number of programs, add the number to the head command with the -n option, e.g. head -n 20.
To check over time if there's increasing memory usage by a program, this command could be run over a time interval, say every few minutes, and logged into a log file for a day, or however long it takes for the computer to slow down. The log file may end up rather large, but the info may be conclusive one way or another, and what's using the memory should become clear.