# 5 Commands to Protect Critical Apps From the Linux OOM Killer

DevFeed: [5 Commands to Protect Critical Apps From the Linux OOM Killer](<https://devfeed.tech/articles/5-commands-to-protect-critical-apps-from-the-linux-oom-killer-95340.md>)

Original publisher: [Read original article](<https://www.tecmint.com/stop-oom-killer-killing-apps/>)

Author: Ravi Saive

Published: 2026-10-22T09:49:33Z

Content type: tutorial

Language: en

Sources: [Tecmint: Linux Howtos, Tutorials & Guides](<https://devfeed.tech/sources/tecmint-linux-howtos-tutorials-guides.md>)

Topics: [Linux](<https://devfeed.tech/topics/linux.md>), [cgroups](<https://devfeed.tech/topics/cgroups.md>), [Kernel](<https://devfeed.tech/topics/kernel.md>)

Tags: [almalinux](<https://devfeed.tech/tags/almalinux.md>), [application](<https://devfeed.tech/tags/application.md>), [applications](<https://devfeed.tech/tags/applications.md>), [apps](<https://devfeed.tech/tags/apps.md>), [apt](<https://devfeed.tech/tags/apt.md>), [btrfs](<https://devfeed.tech/tags/btrfs.md>), [cat](<https://devfeed.tech/tags/cat.md>), [cgroups](<https://devfeed.tech/tags/cgroups.md>), [chmod](<https://devfeed.tech/tags/chmod.md>), [commands](<https://devfeed.tech/tags/commands.md>), [conf](<https://devfeed.tech/tags/conf.md>), [database](<https://devfeed.tech/tags/database.md>), [debian](<https://devfeed.tech/tags/debian.md>), [kernel](<https://devfeed.tech/tags/kernel.md>), [linux](<https://devfeed.tech/tags/linux.md>), [linux-commands](<https://devfeed.tech/tags/linux-commands.md>), [linux-oom-killer](<https://devfeed.tech/tags/linux-oom-killer.md>), [memory](<https://devfeed.tech/tags/memory.md>), [oom](<https://devfeed.tech/tags/oom.md>), [oom-score-adj](<https://devfeed.tech/tags/oom-score-adj.md>), [out-of-memory](<https://devfeed.tech/tags/out-of-memory.md>), [process](<https://devfeed.tech/tags/process.md>), [systemd-memorymax](<https://devfeed.tech/tags/systemd-memorymax.md>)

## AI overview

The excerpt presents five ways to manage Linux out-of-memory events: inspect kernel logs and process OOM scores; adjust a running process with `choom` or persist its priority through systemd's `OOMScoreAdjust`; limit a service with cgroups v2 `MemoryHigh` and `MemoryMax`; add swap for short memory spikes; and use `systemd-oomd` to respond to sustained memory pressure. It distinguishes temporary process adjustments from persistent service settings, and explains that cgroup limits confine OOM kills to the affected service. Full immunity with `OOMScoreAdjust=-1000` can leave the kernel with no killable process and cause a system panic. The excerpt notes platform limits: Btrfs needs a specially created swap file, and Rocky Linux/RHEL may require enabling PSI before `systemd-oomd` can monitor pressure. Swap buys time but does not fix leaks; ongoing OOM events still call for addressing the cause or adding memory.

## Source excerpt

The post 5 Commands to Protect Critical Apps From the Linux OOM Killer first appeared on Tecmint: Linux Howtos, Tutorials & Guides . Your database keeps disappearing overnight, and the only clue is a kernel line saying "Out of memory: Killed process". Here's The post 5 Commands to Protect Critical Apps From the Linux OOM Killer first appeared on Tecmint: Linux Howtos, Tutorials & Guides.