In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "how to configure Java environment variables and Tomcat server". The content of the explanation is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn how to configure Java environment variables and Tomcat server.
Step 1: configure system-consistent jdk environment variables (32-bit / 64-bit)
(1) download the jdk installation package on the official website:
Download address on the official website:
Choose the corresponding installation package according to your operating system (be sure to accept the license agreement)
(2) install jdk:
Install jdk Select installation directory installation prompts appear twice during the installation process. The first time is to install jdk, the second time is to install jre. It is recommended that both are installed in different folders in the same java folder. (cannot all be installed in the root directory of the java folder. Installing jdk and jre in the same folder will cause errors.)
The installation is completed as shown in the following figure
(3) configure environment variables
Configure environment variables after installation of jdk computer → properties → advanced system settings → advanced → environment variables
The system variable → creates a new java-home variable.
The variable value fills in the installation directory of jdk (I am c:\ programfiles\ java\ jdk1.8.0_111)
System variable → looks for path variable → edit
Enter% java-home%\ bin at the end of the variable value
(note whether there is a; sign at the end of the variable value of the original path. If not, enter the; sign first and then enter the above code)
System variable → New classpath variable
Fill in the variable value.;% java-home%\ lib;%java-home%\ lib\ tools.jar (note the first point)
The system variable has been configured.
Step 2: verify that jdk is configured successfully (32-bit / 64-bit)
Verify that the configuration runs cmd successfully. Enter java-version (there is a space between java and-version)
If the version information is displayed as shown in the figure, the installation and configuration are successful.
64-bit as shown below, there will be a clear version comment, if not, it will be 32-bit
Step 3: tomcat9 installation and configuration
(1) download tomcat9 on the official website
Download the latest version of tomcat
Download and install-free. After decompressing this configuration demo, I put it in the d:\ program files\ apache-tomcat-9.0.0.m15 directory.
Pay attention to distinguish 32 from 64-bit jdk, otherwise start tomcat to report a specific error 1
(2) cmd command to configure tomcat
(3) four methods of starting tomcat
Double-click the startup.bat batch under the bin directory to run tomcat. (the advantage is that you can see the running status, the database, and the code error. Recommended)
Run the net starttomcat9 command as an administrator to run cmd (9 is the version number)
Run through the service in the task manager
Double-click tomcat9w.exe in the bin directory and click start to run tomcat. The illustration is as follows:
(4) successful demonstration
Thank you for reading, the above is the content of "how to configure Java environment variables and Tomcat server". After the study of this article, I believe you have a deeper understanding of how to configure Java environment variables and Tomcat server, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
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.