Linux Tomcat installation and one server configuration multiple tomcat

Source: Internet
Author: User
Tags gz file java web server port

Installation environment: Linux (Ubuntu edition)

Installation software: apache-tomcat-9.0.0.m1.tar.gz (http://tomcat.apache.org/)

Step One

Tomcat is one of the open source and free Java Web servers, the Apache Software Foundation project, so install tomcat before installing Java JDK, please refer to Linux JDK installation and configuration (version tar.gz)

Step Two

Download Tomcat9, move file to apache-tomcat-9.0.0.m1.tar.gz move to/usr/tomcat/, and unzip:

  tar -xzvf apache-tomcat-9.0.0.m1.tar.gz

  

and modify the file name

MV Apache-tomcat-9.0.0.m1 apache-tomcat-9.0.0.m1-80

Unzip the apache-tomcat-9.0.0.m1.tar.gz file again, and modify the extracted file price named apache-tomcat-9.0.0.m1-8082, get

  

Step Three

Modify the port to modify the tomcat inside Conf/server.xml

  

There are three port settings in the Server.xml file

<server port= "8005" shutdown= "Shutdown" >: Use when off

<connector port= "8080" protocol= "http/1.1" connectiontimeout= "20000" redirectport= "8443"/>: General application use

<connector port= "8009" protocol= "ajp/1.3" redirectport= "8443"/>: For the AJP port, which is used by the container, such as Apache to access Tomcat's port 8009 via the AJP protocol

The three ports of the first 80 tomcat were modified to: 8005/80/8009

The second 8082 of Tomcat's three ports were modified to: 7082/8082/9082

Step Four

Start Tomcat and enter the bin directory inside Tomcat, respectively

Execution: startup.sh--Start Tomcat

Execution: shutdown.sh-off Tomcat

Browser input: http://ip:80 and http://ip:8082 (IP refers to the IP address of the server) to access different Tomcat

Step Five

Set up tomcat boot up

Linux Tomcat installation and one server configuration multiple tomcat

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.