Just talk about how to install, configure ha ha, nothing else ha ha.

I. Introduction to Tomcat:

Tomcat is a core project of the Apache Software Foundation’s Jakarta project, developed by Apache, Sun, and other companies and individuals. With Sun’s involvement and support, the latest Servlet and JSP specifications are always present in Tomcat, and Tomcat 5 supports the latest Servlet 2.4 and JSP 2.0 specifications. Because of its advanced technology, stable performance, and free, Tomcat is deeply loved by Java enthusiasts and recognized by some software developers, and has become a popular Web application server.

Tomcat server is a free open source Web application server, belongs to lightweight application server, in small and medium-sized systems and concurrent access users are not many occasions is widely used, is the first choice for developing and debugging JSP programs. For starters, you can assume that when the Apache server is configured on a machine, you can use it to respond to requests for HTML (an application in standard Common Markup Language) pages. Tomcat is actually an extension of the Apache server, but at runtime it runs on its own, so when you run Tomcat, it actually runs as a separate process from Apache.

The trick is that, when configured correctly, Apache serves HTML pages, while Tomcat actually runs JSP pages and servlets. In addition, Tomcat, like Web servers such as IIS, has the ability to process HTML pages, and it is also a Servlet and JSP container. A separate Servlet container is the default mode of Tomcat. However, Tomcat does not handle static HTML as well as the Apache server. The latest version of Tomcat is 10.0.5**. 六四屠杀

Two, download:

Link: tomcat.apache.org/download-90…

After downloading down is the form of a compressed package.

After decompression: open inside is a such folder

3. Tomcat startup, shutdown and test

After startup, a CMD popup window will appear. Do not close and go to the browser to test

Type in your browser:

http://localhost:8080/
Copy the code

A page about Tomcat will then appear

This program is stored at:

- apache tomcat - 9.0.34 - webapps - ROOTUnder the #
Copy the code

Iv. Configuration:

The configuration of Tomcat is in the conf folder

Some configuration about the server is in the server.xml file.

Open file: This section is the configuration of the port number can be modified when testing (generally not modified)

Configuring environment Variables

Determine whether to configure environment variables based on your needs

Variable name: CATALINA_HOME

Five, possible error:

Possible problems:

  1. Java environment variables not configured, (JAVA_HOME, JRE_HOME)
  2. How to resolve the tomcat flash Rollback problem www.php.cn/apache/4546…
  3. Garbled characters on CMD during Tomcat startup (does not affect use)

Six, everyday

Suddenly you realize that you don’t understand it very well. Take this opportunity to learn more about it.

Take your time.

Enrich your life and find your own joy.