Linux multiple Tomcat configurations and Tomcat common feature configurations

Source: Internet
Author: User

One, configure multiple Tomcat

Edit environment variable: vi/etc/profile


#java环境配置
Export java_home=/usr/java/jdk1.7.0_71/
Export classpath=.: $JAVA _home/jre/lib/rt.jar: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar
Export path= $PATH: $JAVA _home/bin

#tomcat配置
#tomcat1
Export Catalina_base=/usr/local/tomcat
Export Catalina_home=/usr/local/tomcat
Export Tomcat_home=/usr/local/tomcat
Export path= $PATH:/usr/local/tomcat/bin
#tomcat2
Export Catalina_fafa_1_base=/usr/local/tomcat_tata_1
Export Catalina_fafa_1_home=/usr/local/tomcat_tata_1
Export Tomcat_fafa_1_home=/usr/local/tomcat_tata_1
Export path= $PATH:/usr/local/tomcat_tata_1/bin

To the second Tomcat Bin directory, add the catalina.sh in the
Export java_home=/usr/java/jdk1.7.0_71/
Export classpath=.: $JAVA _home/jre/lib/rt.jar: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar
Export path= $PATH: $JAVA _home/bin
Export catalina_base= $CATALINA _fafa_1_base

Export Catalina_home= $CATALINA _fafa_1_home

To change the port:

The first Tomcat, keep the original after decompression without modification,The second Tomcat modifies the Server.xml configuration and the first different boot, shutdown listening ports. The following examples are modified:<server port= "9005" shutdown= "shutdown" > Port: 8005->9005<!--Define a non-sslhttp/1.1 Connector on port 8080--<connector port= "9080" maxhttpheadersize= "8192"Port: 8080->9080maxthreads= "minsparethreads=" maxsparethreads= "75"Enablelookups= "false" redirectport= "8443" acceptcount= "100"connectiontimeout= "20000" disableuploadtimeout= "true"/><!--Define an AJP1.3 Connector on port 8009-<connector port= "9009" Port: 8009->9009Enablelookups= "false" redirectport= "8443" protocol= "ajp/1.3"/>

Linux multiple Tomcat configurations and Tomcat common feature configurations

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.