linux關於tomcat的一些命令筆記

root權限的tomcat 關閉與啓動
[ root@VM_146_195_centos  /]# tomcat stop  
[ root@VM_146_195_centos  /]# tomcat start 

找到tomcat下bin目錄:
啓動: ./startup.sh
關閉:./shutdow.sh

查看80開頭端口使用狀態
[ root@VM_146_195_centos  /]# netstat -anp | grep 80 | grep LISTEN 
tcp 0 0           :::8009                          :::     * LISTEN 27553/java
tcp 0 0           :::80                              :::*      LISTEN 27553/java      

查看正在使用80端口的進程
[ root@VM_146_195_centos  /]# lsof -i:80 
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME 
java 21739 root 38u IPv6 10084909 0t0 TCP *:http (LISTEN) 

幹掉此進程
[ root@VM_146_195_centos  /]# kill -9 21739 
相關文章
相關標籤/搜索