Home > Article > Operation and Maintenance > How to view Linux services
1. ps aux or netstat -tlunp
ps is the process viewing command, netstat is the port viewing command, in Linux system , the service must have a process, so you can use the ps command to check the service running status. In addition, most Linux services are network services, so you can also check the service running status through the netstat command. (Recommended learning: linux tutorial)
2. service service name status
For example, check the running status of the httpd Web service, Execute service httpd status, as shown in the following figure:
3, /sbin/service --status-all |grep "service name"
For example, to view the web service of httpd, execute /sbin/service --status-all |grep "httpd". As shown below.
4. chkconfig --list
For example, to view the httpd web service, execute chkconfig --list |grep "httpd" will do. As shown below.
The above is the detailed content of How to view Linux services. For more information, please follow other related articles on the PHP Chinese website!