Linux installs Tomcat and releases the war package

Source: Internet
Author: User

1,jdk

Download JDK

Unzip the JDK and place it under the/usr/local path

/usr/local/jdk1.7.0_67

Make a soft connection

Ln-s/usr/local/jdk1.7.0_67//USR/LOCAL/JDK

Modify the/etc/profile file

Add the following content

######################################
Export java_home=/usr/local/jdk1.7.0_67

Export path= $JAVA _home/bin: $PATH
Export classpath= $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar

Path variable this place in the order of the position is reversed, resulting in a lot of commands can not be used, the file may be down, modified after the transfer up, restart can be restored

Source/etc/profile

View the next

[Email protected] jdk1.7.0_67]# java-version
Java Version "1.7.0_67"
Java (TM) SE Runtime Environment (build 1.7.0_67-b01)
Java HotSpot (TM) Server VM (build 24.65-b04, Mixed mode)
[Email protected] jdk1.7.0_67]#

2. Tomcat

After downloading the corresponding version of Tomcat, it is also extracted to/usr/local

/usr/local/apache-tomcat-7.0.53

Make a soft connection

Ln-s/usr/local/apache-tomcat-7.0.53//usr/local/tomcat

Gives 755 permission

Modify VI tomcat/bin/catalina.sh File

Add the following content

#######################
catalina_home=/usr/local/apache-tomcat-7.0.53/

Start Tomcat

[[email protected] local]#/usr/local/tomcat/bin/catalina.sh start

Stop it.

/http (Tomcat IP): 8080

You can open it and you're successful.

3 Release War Package

Copy the war package to the tomcat/webapps/path

Restart Tomcat. It will automatically unzip and release the

Log in and see if it's successful.

To modify the configuration, go to the corresponding path under the Web-inf path to find the corresponding file

Linux installs Tomcat and releases the war package

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.