Debian

Debian List all Running Services

Service in any operating system is defined as a background application that keeps waiting for clients’ requests. Once it receives those requests, it performs the necessary actions so that the request can be served accordingly. Service always has a status associated with it, such as active, enabled, running, inactive, dead, etc. A system administrator is mainly concerned with the services that are currently running on an operating system. In today’s article, we will explore the different methods of listing all the running services in Debian 10.

Methods of listing all Running Services in Debian 10:

For listing all the running services in Debian 10, you can select any of the following three methods:

Method # 1: Using the “systemctl” command with the “list-units” Parameter in Debian 10:

You can use the “systemctl” command with the “list-units” parameter to list down all the running services in Debian 10 in the manner shown below:

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

When you execute the above-mentioned command, a list of all the running services in Debian 10 will be displayed on your terminal, which is shown in the following image:

Method # 2: Using the “systemctl” command without the “list-units” Parameter in Debian 10:

You can use the “systemctl” command without the “list-units” parameter to list down all the running services in Debian 10 in the manner shown below:

$ systemctl --type=service --state=running

When you execute the above-mentioned command, a list of all the running services in Debian 10 will be displayed on your terminal, which is shown in the following image:

Method # 3: Using the “pstree” Command in Debian 10:

You can use the “pstree” command to list down all the running services in Debian 10 in the manner shown below:

$ pstree

When you execute the above-mentioned command, a list of all the running services in Debian 10 will be displayed in a nice and clean tree-like structure on your terminal, which is shown in the following image:

Conclusion:

The three methods shared with you in this article aimed to demonstrate to you how you can list all the running services in Debian 10. You can employ the very same methods on Ubuntu 20.04 and Linux Mint 20, whereas the commands for CentOS 8 may differ slightly. Nevertheless, you can conveniently pick any method of your choice out of the ones shared with you in this article for listing down all the running services in Debian 10.

About the author

Karim Buzdar

Karim Buzdar

Karim Buzdar holds a degree in telecommunication engineering and holds several sysadmin certifications. As an IT engineer and technical author, he writes for various web sites. He blogs at LinuxWays.