How to View Running Services in Linux Using the systemctl Command

A Linux server is not just a static hard drive holding files; it is a complex, highly active ecosystem of background programs (known as daemons) constantly working together to keep the machine alive and functioning. These invisible services manage your network connections, run your web servers (like Apache or Nginx), host your databases (like MySQL), and enforce your firewalls. If a website suddenly goes offline or a database connection drops, you cannot rely on graphical error messages to diagnose the issue. You need to look directly at the kernel to see exactly which background service has crashed. You can view the real-time status of every single service on your machine using the powerful systemctl command.

How to View All Running Services

Modern Linux distributions (like Ubuntu, Debian, and CentOS) use the systemd initialization system, which is entirely managed by the systemctl utility.

To view a complete, exhaustive list of every single background service that is currently active and running on your server, type the following command into your terminal and press Enter:

systemctl list-units --type=service --state=running

The kernel will output a clean, formatted table. The most important column is the leftmost one, which lists the exact name of the service (e.g., ssh.service or nginx.service). The subsequent columns confirm that the service is loaded, active, and functioning properly, followed by a brief human-readable description of what the daemon actually does.

How to Check the Status of a Specific Service

If you already suspect that a specific service has crashed (for example, your UFW firewall or your Docker engine), you do not need to scroll through a massive list. You can ask the kernel for a highly detailed status report on that specific daemon.

To check the status of a specific service, type systemctl status followed by the name of the service. For example:

systemctl status ufw

Press Enter. The terminal will output a color-coded block of text. If the service is healthy, you will see a bright green active (running) message. Crucially, the bottom of the output will display the most recent 10 lines from that service’s internal log file, which is absolutely vital for debugging exactly why a service failed to start.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.