首页 | 新闻 | 交流 | 问吧 | 文档 | 手册 | 下载 | 博客

Apache+多tomcat组成load balance(tomcat非集群)(2)

作者:  时间: 2010-10-11

Tomcat配置:

  1. 修改SHUTDOWN端口(tomcat的关闭端口)

    tomcat1<Server port="8005" shutdown="SHUTDOWN">
    tomcat2
    <Server port="
    9005" shutdown="SHUTDOWN">

     

  2. 修改运行端口

    因为tomcat有两个,因此只需要修改其中某一个tomcat运行的端口即可:
    tomcat1

    <Connector port="
    8080" protocol="HTTP/1.1" 
                   connectionTimeout="20000" 
                   redirectPort="8443" />
    tomcat2

    <Connector port="
    9080" protocol="HTTP/1.1" 
                   connectionTimeout="20000" 
                   redirectPort="8443" />
    注:只需要修改port参数,不用修改redirectPort参数

     

  3. 修改connector的端口

    tomcat1<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />
    tomcat2
    <Connector port="
    8019" protocol="AJP/1.3" redirectPort="8443" />