Check Running Services CentOS 7

On CentOS 7, you can use the following command to view the running services:

  1. Use the systemctl command:
systemctl list-units --type=service --state=running

This will list all the services currently running.

  1. Search for a specific service, such as the running SSH service, using the systemctl command combined with the grep command.
systemctl list-units --type=service --state=running | grep ssh

This will list all service names containing “ssh”.

  1. Check the status of a specific service using the systemctl command, for example, checking the status of the ssh service.
systemctl status ssh

This will display detailed information about the ssh service, including whether it is running, the last time it was started, and more.

With these commands, you can easily view the services running on CentOS 7.

bannerAds