转:Linux下查看tomcat占用端口
https://blog.csdn.net/liufuwu1/article/details/71123597[root@server-crm mysql]# ps -ef | grep "tomcat"
root 11098 1 0 17:48 pts/0 00:00:12 /usr/lib/jvm/jre/bin/java -classpath :/usr/share/tomcat/bin/bootstrap.jar:/usr/share/tomcat/bin/tomcat-juli.jar:/usr/share/java/commons-daemon.jar -Dcatalina.base=/usr/share/tomcat -Dcatalina.home=/usr/share/tomcat -Djava.endorsed.dirs= -Djava.io.tmpdir=/var/cache/tomcat/temp -Djava.util.logging.config.file=/usr/share/tomcat/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager org.apache.catalina.startup.Bootstrap start root 12014 5231 0 20:19 pts/0 00:00:00 grep tomcat [root@server-crm mysql]# netstat -anop | grep 11098 tcp 0 0 ::ffff:127.0.0.1:8005 :::* LISTEN 11098/java off (0.00/0/0) tcp 0 0 :::8009 :::* LISTEN 11098/java off (0.00/0/0) tcp 0 0 :::8080 :::* LISTEN 11098/java off (0.00/0/0) unix 2 [ ] STREAM CONNECTED 42031 11098/java
[root@server-crm webapps]# lsof -i:8080
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 11098 root 45u IPv6 42033 0t0 TCP *:webcache (LISTEN)