Site icon New Generation Enterprise Linux

When `systemctl status` lies about a dead service

Process & Resource Monitoring (Top/Htop/Ps/Systemd)

When `systemctl status` lies about a dead service

đź§© The Challenge

You just restarted a service, or it just crashed, and you run `systemctl status my-app.service` and it says it’s active. But you know for a fact it’s not working. It’s happened to me. I’ve wasted hours trying to figure out why it’s “running” but not actually doing anything.

đź’ˇ The Fix

Don’t just trust `systemctl status` when a service is acting weird. There’s a quick way to check if the actual process is still kicking around, even if systemd thinks it’s fine.

pgrep -fl my-app

⚙️ Why It Works

This command searches for processes whose name contains “my-app” and it lists the full command line for each match. If you see nothing, the process is definitely dead, regardless of what systemd claims.

🚀 Pro-Tip: Pipe `pgrep` output to `wc -l` to just get a number of running instances.

Linux Tips & Tricks | © ngelinux.com | 10/7/2026

0 0 votes
Article Rating
Exit mobile version