1、ps aux 或netstat -tlunp
ps是進程查看命令,netstat是端口查看命令,在linux系統中,服務一定是有進程的,所以使用ps命令可以查看服務運行情況,另外,Linux服務多數是網絡服務,所以通過netstat命令也可以查看服務運行狀態。? ? ? ? ? ? ? ? ? ? ? ? ?(推薦學習:linux教程)
2、service 服務名? status
?比如查看httpd的Web服務的運行狀態,執行service httpd status,如下圖所示:
3、/sbin/service –status-all |grep “服務名”
比如查看httpd的web服務,執行 /sbin/service –status-all |grep “httpd”即可。如下圖所示。
4、chkconfig –list
比如查看httpd的web服務,執行 chkconfig –list |grep “httpd”即可。如下圖所示。
? 版權聲明
文章版權歸作者所有,未經允許請勿轉載。
THE END