Tomcat实战之基础篇

 

环境:Tomcat 7.0.6

 

>>修改Tomcat端口:

修改tomcat\conf\server.xml里8080为7080:

<!-- A "Connector" represents an endpoint by which requests are received
         and responses are returned. Documentation at :
         Java HTTP Connector: /docs/config/http.html (blocking & non-blocking)
         Java AJP  Connector: /docs/config/ajp.html
         APR (HTTP/AJP) Connector: /docs/apr.html
         Define a non-SSL HTTP/1.1 Connector on port 8080
    -->
    <Connector connectionTimeout="20000" port="7080" protocol="HTTP/1.1" redirectPort="8443"/>
    <!-- A "Connector" using the shared thread pool-->
    <!--
    <Connector executor="tomcatThreadPool"
               port="8080" protocol="HTTP/1.1" 
               connectionTimeout="20000" 
               redirectPort="8443" />
    -->

>>Tomcat里添加额外的共享项目lib包

修改tomcat\conf\catalina.properties里:

shared.loader=${catalina.home}/lib_ext/company/*.jar,${catalina.home}/lib_ext/my/*.jar

你可能感兴趣的:(tomcat)