Ubuntu 22.04 LTS Integrating systemd-oomd For Improving Low Memory Handling

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • sbivol
    replied
    Originally posted by Danny3 View Post
    I'm sure it will come with an exception for Snap crap or other shitty things from Canonical so they can consume as much memory as they want or never bekilled.
    Where have Snap and Canonical touched you? Have you filed a complaint with the police?

    Leave a comment:


  • RedEyed
    replied
    Originally posted by Draget View Post
    I have not tried systemd-oomd. But it always bothered me that despite testing different io-schedulers, swap configurations etc. I had major issues in OOM situations on super powerful servers, small servers, desktops, laptops, hdds and ssds for many years. One of the things I never understood, why Linux seems to handle memory-pressure situations so poorly.

    I expect it to be super slow with swap and nuke some processes if there is no other way, but not become unresponsive for minutes or completely lock up, crash etc. Looking forward to test it.
    I was annoyed by unresponsiveness like you, but once I found the earlyoom package (mb 4 years ago) I forgot about freezing.

    I just need responsiveness, if some process becames too hungry, let just kill it, instead of unresponsive machine

    Leave a comment:


  • hakavlad
    replied
    Originally posted by tildearrow View Post
    Have you tried sending the patch to Linus directly?
    Not yet.

    The first attempt is here: https://lore.kernel.org/lkml/2021113...mail.inbox.lv/
    I didn't justify the need to add new sysctl knobs in detail. Before sending the patch to Linus, I hope to justify the need to add new knobs in more detail, as well as respond to objections from the community.

    Leave a comment:


  • qarium
    replied
    Originally posted by krzyzowiec View Post
    I solved my problem by acquiring 64GB of RAM for my desktop. The XanMod kernel also seems to save a lot of memory for me over the standard kernel somehow.
    I have 128GB ECC ram and also i am used to disable hyperthreading to make sure no extra ram is used for that.

    Leave a comment:


  • hakavlad
    replied
    Originally posted by abu_shawarib View Post
    I had freezes (no ctl+alt+F#) from running out of memory even on 21.10 and 20.04. Kinda unacceptable that it happens for a modern OS.
    Seems like Ubuntu is not modern OS. Fedora solved the problem at 2019: https://pagure.io/fedora-workstation/issue/98

    Leave a comment:


  • hakavlad
    replied
    Originally posted by sb56637 View Post
    From what I understand systemd-oomd works on the cgroup, so for most desktops outside of Gnome that would mean it takes down the entire desktop session if it has to intervene. Maybe someone who understands better could comment on this.
    It's true. It's possible even with GNOME! https://lists.fedoraproject.org/arch...UPFQNLYHHGMJU/

    See also







    Leave a comment:


  • hakavlad
    replied
    Originally posted by Vorpal View Post
    The article reads "50% memory pressure limit for user sessions". Is memory pressure the same as memory usage? If so that seems low. Why not allow the user to use something like 90% ram?

    I often run memory intensive computational tasks, though I tune them to leave a couple of GB (out of my 32 GB) to the system, X etc.

    ​​​​​
    50% memory pressure is not 50% memory usage. See https://facebookmicrosites.github.io/psi/docs/overview
    Last edited by hakavlad; 01 February 2022, 06:10 PM.

    Leave a comment:


  • hakavlad
    replied
    Originally posted by Draget View Post
    I expect it to be super slow with swap
    Why it should be slow? I don't know how to freeze a properly configured system.

    for example,
    Code:
    for i in {1..100}; do (tail /dev/zero &); done
    https://www.youtube.com/watch?v=tsnA6Mx-MpQ -- no freeze with swap. (swap on zram, fs on HDD, no userspace OOM killer)
    Last edited by hakavlad; 01 February 2022, 05:54 PM.

    Leave a comment:


  • hakavlad
    replied
    Originally posted by Draget View Post
    I had major issues in OOM situations on super powerful servers, small servers, desktops, laptops, hdds and ssds for many years. One of the things I never understood, why Linux seems to handle memory-pressure situations so poorly.
    Michal Hocko answers:

    https://lore.kernel.org/lkml/YbcNUEZ...hcp22.suse.cz/

    Adding new knobs to improve performance under memory pressure is a pain for mm maintainers. In words they may be in favor of solving the problem, but when it comes to business, they will find thousands of objections (some of them, of course, are correct).
    Last edited by hakavlad; 01 February 2022, 05:18 PM.

    Leave a comment:


  • tildearrow
    replied
    Originally posted by hakavlad View Post

    No one is interested in these amateur creations. system-oomd is a proven solution from respected developers.
    It's very sad because you truly did an amazing job fixing the hang problem.
    I was trying to do a speedrun a week ago, and the timer had a memory leak problem which caused it to eat the system's memory.
    Had it not been for le9 + prelockd, my system would have hung and been unresponsive without explanation. With your patches, the timer promptly closed, and the game kept running without a single lag spike.

    Have you tried sending the patch to Linus directly? I know it's mostly tuning options, but these really come in handy.

    Leave a comment:

Working...
X