Catch your runaway processes before they kill the system
Process & Resource Monitoring (Top/Htop/Ps/Systemd)
Catch your runaway processes before they kill the system
🧩 The Challenge
Dealing with a Java app or a stray PHP-FPM worker that slowly eats all your RAM until the OOM killer starts nuking innocent processes is a special kind of hell. You end up staring at htop, but it never shows you the full picture of what’s been hogging the bucket over time.
💡 The Fix
Start using the cgroups v2 accounting tools that are built into systemd. It lets you see the peak memory usage of a slice or service without having to babysit the console with a stopwatch.
systemd-cgtop -p
⚙️ Why It Works
This utility hooks into the cgroup controller to show real-time resource pressure for services, rather than just raw process IDs. It turns that chaotic list of random PIDs into a sane hierarchy you can actually read.
🚀 Pro-Tip: Pipe this into grep if you are only hunting for a specific service slice to avoid the noise.
Linux Tips & Tricks | © ngelinux.com | 9/13/2026
