如何在Linux中修改tomcat端⼝号我这⾥有好⼏个tomcat,同时使⽤的话就要给端⼝号改成不⼀样的:
1、⾸先cd进tomcat⽬录⾥的conf⽂件夹,vi打开l配置⽂件
[root@localhost soft]# ls
download redis solrhome tomcat-sina-8081 tomcat-souhu-8082
jdk redis-3. tomcat tomcat-solr zookeeper-3.4.6
[root@localhost soft]# cd tomcat-solr/
[root@localhost tomcat-solr]# cd conf/
[root@localhost conf]# ls
Catalina catalina.properties logging.l
catalina.l l l
[root@localhost conf]# l
2、改动之⼀
8005改成了8885
<Server port="8885" shutdown="SHUTDOWN">
<!-- Security listener. Documentation at /docs/config/listeners.html
<Listener className="org.apache.catalina.security.SecurityListener" />
3、改动之⼆
8080改成了8888xml文件怎么打开
<Connector port="8888" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
4、改动之三
8009改成了8889
<!-- Define an AJP 1.3 Connector on port 8009 -->
<Connector port="8889" protocol="AJP/1.3" redirectPort="8443" />
5、wq保存退出
最后在tomcat的bin⽬录./startup.sh启动⼀下试试:OK
发布评论