Announcement

Collapse
No announcement yet.

Linux 5.15 Adds New Syscall To More Quickly Free Memory Of Dying Processes

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

  • andreano
    replied
    I'm not sure I like (or understand the reason for) its small scope. There is still the problem that you can't kill processes that are in uninterruptible sleep.

    Every time you have a process using a file on a network filesystem from a machine on a network you are no longer connected to, you can't kill it (not even kill -9). You have to reboot. That's not useful, and is something that needs fixing anyway. Couldn't this syscall clean it up all the way, while they're adding it, so we don't need yet another for that?
    Last edited by andreano; 07 September 2021, 01:46 PM.

    Leave a comment:


  • carewolf
    replied
    Just fix the restore from starting to use swap memory, it is what is killing everything that Linux never recovers from a swap condition. It doesn't try, and if you force it by disabling swap, it takes 10-100x longer than it should.

    Leave a comment:


  • boxie
    replied
    Originally posted by hakavlad View Post

    does it get to run any code? - no

    is execution immediately halted? - yes

    Memory is not released instantly, but `/proc/pid/statm` shows 0 0 0 0 0 immediately after sending SIGKILL to the process.

    Memory can be released for a few seconds if the process is large and some of its memory is in the swap space.
    thank you for a very nice explanation!

    Leave a comment:


  • hakavlad
    replied
    Originally posted by boxie View Post
    What happens to the dying process? does it get to run any code? is execution immediately halted?
    does it get to run any code? - no

    is execution immediately halted? - yes

    Memory is not released instantly, but `/proc/pid/statm` shows 0 0 0 0 0 immediately after sending SIGKILL to the process.

    Memory can be released for a few seconds if the process is large and some of its memory is in the swap space.
    Last edited by hakavlad; 07 September 2021, 06:40 AM.

    Leave a comment:


  • hakavlad
    replied
    Originally posted by StarterX4 View Post
    And what about Zombie processes? Another syscall would be needed.
    VmRSS=0 if state=Z, no syscall needed.

    Leave a comment:


  • StarterX4
    replied
    And what about Zombie processes? Another syscall would be needed.

    Leave a comment:


  • pal666
    replied
    Originally posted by boxie View Post
    What happens to the dying process? does it get to run any code? is execution immediately halted?
    subj talks about process sleeping in uninterruptible sleep, it doesn't run anything, just waits

    Leave a comment:


  • boxie
    replied
    What happens to the dying process? does it get to run any code? is execution immediately halted?

    Leave a comment:


  • sinepgib
    replied
    Originally posted by pipe13 View Post
    Not even properly dead and already harvesting its organs
    Well, you know, the fresher the better.

    Leave a comment:


  • pipe13
    replied
    Not even properly dead and already harvesting its organs

    Leave a comment:

Working...
X