windows 配置多个tomcat服务器

如何同时启动多个Tomcat服务器

多个eclipse开发需要在windows上同时启动多个Tomcat服务器

我所用Tomcat服务器都为zip版,非安装版。以两个为例:

安装第二个Tomcat完成后,到安装目录下的conf子目录中打开server.xml文件,查找以下三处:

(1)修改http访问端口(默认为8080端口)

<Connectorclassname="org.apache.coyote.tomcat4.CoyoteConnector"port="8080"

minProcessors="5"maxProcessors="75"

enableLookups="true"redirectPort="8443"

acceptCount="100"debug="0"connectionTimeout="20000"

useURIValidationHack="false"disableUploadTimeout="true"/>

将8080修改为第一个tomcat不在使用的端口号如9090。此处所设的端口号即是以后访问web时所用的端口号。

(2)修改Shutdown端口(默认为8005端口)

<Serverport="8005"shutdown="SHUTDOWN"debug="0">

将8005修改为没有在使用的端口号,例如8085

(3)修改JVM启动端口(默认为8009端口)

<Connectorclassname="org.apache.coyote.tomcat4.CoyoteConnector"

port="8009"minProcessors="5"maxProcessors="75"

enableLookups="true"redirectPort="8443"

acceptCount="10"debug="0"connectionTimeout="20000"

useURIValidationHack="false"

protocolHandlerClassname="org.apache.jk.server.JkCoyoteHandler"/>

将8009修改为没有在使用的端口号,例如8008

这样就没问题了。

相关推荐