Java+Tomcat environment deployment and installation process diagram

Java+Tomcat environment deployment and installation process diagram

Next, I will install Java+Tomcat on Centos7. There are many articles on the Internet, and I have some problems in deployment. The following is an installation process I summarized myself!

Install Java Environment

First, we go to the Java official website to download JDK. Here I download the jdk1.8 version.

https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Click Accept License Agreement and select the version to download. You need to register an Oracle account to log in and download!

Copy the downloaded jdk package to the Centos7 root directory. It is recommended to use WinSCP

Create a Java installation directory

mkdir -p /usr/local/java

Unzip the jdk package to the java installation directory

tar -zxvf jdk-8u211-linux-x64.tar.gz -C /usr/local/java/

Configuring environment variables

vim /etc/profile.d/java.sh

export JAVA_HOME=/usr/local/java/jdk1.8.0_211
export CLASS_PATH="$JAVA_HOME/lib:$JAVA_HOME/jre/lib"
export PATH=$PATH:$JAVA_HOME/bin

Make the configuration take effect immediately

source /etc/profile

Verify that the Java environment is configured successfully


Install Tomcat environment

Download the installation package from the official website: https://tomcat.apache.org/

Here I choose Tomcat8 Archives to view historical versions


Here I choose version v8.5.5. Remember not to enter the src directory to download the installation package. You will encounter the problem of not finding bootstarp.jar in the bin directory. Enter the bin directory and download the code package.


Unzip to the installation directory

tar -zxvf apache-tomcat-8.5.5.tar.gz -C /usr/local/

Creating a Soft Link

cd /usr/local/
ln -sv apache-tomcat-8.5.5 tomcat

Configuring environment variables

vim /etc/profile.d/tomcat.sh

CATALINA_BASE=/usr/local/tomcat
PATH=$CATALINA_BASE/bin:$PATH
export PATH CATALINA_BASE

Make the configuration take effect

source /etc/profile.d/tomcat.sh

Check the tomcat version status

Enter the bin directory of tomcat

cd /usr/local/tomcat/bin/

Grant Permission

chmod 755 *

View configuration information

./catalina.sh version


Start Tomcat service

./startup.sh


If the above content appears, it means success. Now visit ip:8080 to see


Summarize

The above is the graphic illustration of Java+Tomcat environment deployment and installation process introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!
If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

You may also be interested in:
  • Dockerfile deployment java web environment detailed explanation
  • Installation of Tomcat9 and deployment of web projects under Linux CentOS
  • IntelliJ IDEA uses Maven to implement hot deployment of Tomcat
  • How to package Maven project into war package and deploy it to Tomcat

<<:  (MariaDB) Comprehensive explanation of MySQL data types and storage mechanisms

>>:  JS Object constructor Object.freeze

Recommend

Nginx configuration based on multiple domain names, ports, IP virtual hosts

1. Type introduction 1.1 Domain-based virtual hos...

Detailed explanation of how to use element-plus in Vue3

Table of contents 1. Installation 2. Import in ma...

The main differences between MySQL 4.1/5.0/5.1/5.5/5.6

Some command differences between versions: show i...

How to use .htaccess to prohibit a certain IP from accessing the website

Preface For cost considerations, most webmasters ...

JavaScript's unreliable undefined

undefined In JavaScript, if we want to determine ...

Introduction to the use of em in elastic layout in CSS3: How many pixels is 1em?

I have been using CSS for a long time, but I have...

How to pass the value of the select drop-down box to the id to implement the code

The complete code is as follows : HTML code: Copy ...

Detailed explanation of Vue's TodoList case

<template> <div id="root"> ...

Detailed explanation of MySQL date string timestamp conversion

The conversion between time, string and timestamp...

js to realize payment countdown and return to the home page

Payment countdown to return to the home page case...

Summary of Vue's cross-domain problem handling and solutions

When you send a network request, the following sa...

Some small methods commonly used in html pages

Add in the <Head> tag <meta http-equiv=&q...

Problems and solutions when replacing Oracle with MySQL

Table of contents Migration Tools Application tra...