In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article shows you how to achieve multi-port configuration in Tomcat 7.0. the content is concise and easy to understand, which will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.
Modify the server.xml file in the tomcat/conf directory
For example, add a new port 8081 and set up the appBase directory, so that you can listen to multiple ports with one tomcat, and each port can be used for application. After I add the following configuration in this way, tomcat listens on 2 ports (8080pr 8081)
The applications of webapps directory and webapps1 directory will be started, and the applications can be accessed according to different ports.
OK
Rename the project war package to ROOT and start the service under the path specified by the appBase attribute.
Attached: Tomcat port description:
1. Use notepad to open the server.xml file in the conf folder in the Tomcat installation directory.
two。 Find the following code in the server.xml file:
(1)
This connector is responsible for establishing a HTTP connection. This port is used when accessing the web application of the Tomcat server through the browser. If this port is occupied, you can modify an unoccupied port, for example, by changing port= "8080" in the above code to port= "8081", the default port of Tomcat can be set to 8081. When modifying ports, conflicts with public ports should be avoided. It is recommended to use the default port 8080 and do not modify it unless port 8080 is occupied by other programs.
(2)
Port 8005 is the port used to shut down Tomcat services. If this port is occupied, you can change 8005 to another port in the configuration file.
(3)
This connector is responsible for establishing connections with other HTTP servers and is required to integrate Tomcat with other HTTP services. If this port is occupied, you can change 8009 to another port in the configuration file
(4)
The function of this connector is to start the HTTPS service. In general, this section is commented out and will only be used freely when the HTTPS service is enabled. If this port is occupied, modify port 8443 to other ports that are not occupied, and you also need to modify the ones in (1) and (3).
3. After the modification is successful, you also need to restart the Tomcat server in order for the newly set port to take effect.
The above is how to implement multi-port configuration in Tomcat 7.0. have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.