Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to view the service status information of linux

Shulou Source: shulou.com Published: 2022-06-03 02:52:11 09月22日 Update

How do we see which service is running on our Linux system? First, let's enter the following command:

Ps-ef

Let's first take a look at whether the system includes this service. For example, I want to take a look at my nginx server (pay attention to case):

Ps-ef | grep nginx

If you want to kill the service, use the following command:

Kill ID

You can use either of the above commands to get ID, the second column is ID, and you get the same ID (the third line is the ID you just typed in to search).

To see the detailed status of this service, we can use the following command:

Service nginx status

The other commands are as follows (I'll take nginx as an example here):

Restart the service: sudo service nginx restart start the service: sudo service nginx start stop the service: sudo service nginx stop

These are the details of how linux views service status information. For more information, please follow other related articles!

Tags: Services commands use status system input information same content can make size that is articles more server three lines search run Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Microsoft Huawei vpn Apple MySQL