oomstaller(1)

πŸ“¦ version 0.3.0, in opensuse-leap 16.0

🌸 NAME 🌸

okay so bestie, meet oomstaller(1) πŸ’– β€” the command is oomstaller, and its whole job is to suppress swap thrashing at build time. no cap.


✨ SYNOPSIS ✨

oomstaller [<options>] command [arg] ...

πŸ’… DESCRIPTION πŸ’…

real talk: this tool monitors the memory usage of each process when you're performing a build, and it suspends processes as necessary to prevent swap thrashing from happening. it's giving responsible build main character energy ✨

to perform a build using this tool, specify make or ninja as the argument of this tool and execute it like this:

$ oomstaller make -j `nproc`

πŸŽ€ OPTIONS πŸŽ€

  • --thres <percentage, default=75> β€” suspends processes so that memory usage by running build processes does not exceed the specified percentage of available memory. keep it under the vibe limit πŸ’…
  • --max-parallel <number of processes, default=0> β€” suspends processes so that the number of running build processes does not exceed the specified number. 0 means no limit. a process is counted as one process even if it has multiple threads. one process = one process, threads don't get extra headcount 🫢
  • --max-parallel-thrash <number of processes, default=1> β€” specifies the maximum number of processes to run when thrashing is detected. 0 means no limit. emergency thrash mode gets its own cap ⭐
  • --period <seconds, default=1> β€” specifies the interval at which memory usage of each process is checked and processes are controlled. the check-in rhythm πŸŽ€
  • --thrash <minimum available memory (MB), default=256> β€” if the amount of available memory falls below the specified value, it is assumed that swap thrashing is occurring. below that line = thrash o'clock 😭
  • --show-stat β€” displays statistics when finished. receipts at the end πŸ’–

🫢 TIPS 🫢

⚠️ important caveat bestie: if you kill this tool with SIGKILL, a large number of build processes will remain suspended with SIGSTOP. not slay. to prevent this from happening, use SIGTERM or SIGINT to kill this tool. πŸ™ˆ

you can send SIGCONT to all processes run by you with the following command:

$ killall -v -s CONT -u $USER -r '.*'

πŸ¦‹ SEE ALSO πŸ¦‹

πŸ‘‘ AUTHOR πŸ‘‘

Naoki Shibata (shibatch@users.sourceforge.net) the legend behind the tool πŸ‘‘


version 0.3.0 β€’ dated 01 Dec 2024 β€’ oomstaller(1) β€” mwah, go build safely πŸ’‹βœ¨

πŸ“¦ where this page comes from