linux查看tomcat端口
时间: 2023-04-27 11:00:22 浏览: 200
linux版的tomcat
要查看Tomcat端口,可以使用以下命令:
1. 首先,进入Tomcat安装目录的bin目录:
cd /usr/local/tomcat/bin
2. 然后,运行以下命令:
./catalina.sh configtest
3. 如果Tomcat配置正确,将输出以下内容:
Using CATALINA_BASE: /usr/local/tomcat
Using CATALINA_HOME: /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME: /usr/lib/jvm/java-8-openjdk-amd64
Using CLASSPATH: /usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar
Server version: Apache Tomcat/8.5.61
Server built: Jul 6 2021 10:57:35 UTC
Server number: 8.5.61.0
OS Name: Linux
OS Version: 5.4.0-1045-aws
Architecture: amd64
JVM Version: 1.8.0_292-b10
JVM Vendor: Oracle Corporation
4. 在输出中,可以找到以下行:
INFO: Starting ProtocolHandler ["http-nio-8080"]
这表明Tomcat正在使用8080端口。
阅读全文