Installing TOMCAT8
Go to http://tomcat.apache.org/download-80.cgi to download the TOMCAT8 installation file apache-tomcat-8.0.26.tar.gz.
Place the apache-tomcat-8.0.26.tar.gz file in the/usr/local directory and execute the following script:
# cd/usr/local # TAR-ZXVF apache-tomcat-8.0.26.tar.gz//Decompression Pack # RM-RF apache-tomcat-8.0.26.tar.gz.tar.gz//delete compression Pack # MV apache-tomcat-8.0.26 Tomcat
Start TOMCAT8
#/usr/local/tomcat/bin/startup.sh//start Tomcat
Using catalina_base:/usr/local/tomcat
Using Catalina_home:/usr/local/tomcat
Using Catalina_tmpdir:/usr/local/tomcat/temp
Using Jre_home:/usr/java/jdk1.8.0_60
Using CLASSPATH:/usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/tomcat-juli.jar
Tomcat started.
If the following error occurs:
Neither the Java_home nor the JRE_HOME environment variable is defined
At least one of these environment variable are needed to run this program
Be careful to set the Java path in advance
Add content to apache-tomcat-8.0.26/bin/setclasspath.sh
Export JAVA_HOME=/USR/JAVA/JDK1.8.0_60 export JRE_HOME=/USR/JAVA/JDK1.8.0_60/JRE export classpath=.: $JAVA _home/lib: $JRE _home/lib: $CLASSPATH export path= $JAVA _home/bin: $JRE _home/bin: $PATH
Firewall Open 8080 Port
Add 8080 ports to the firewall configuration and do the following:
# Vi/etc/sysconfig/iptables
#增加以下代码
-A rh-firewall-1-input-m state--state new-m tcp-p TCP--dport 8080-j ACCEPT
Restarting the firewall
# Service Iptables Restart
Inspection TOMCAT8 Installation and operation
See if Tomcat is working properly with the following address:
http://192.168.11.52:8080/
See the Tomcat system interface to show that the installation was successful!
Stop Tomcat8
#/usr/local/tomcat/bin/shutdown.sh//Stop Tomcat
This article is from the SQL Server deep dives blog, so be sure to keep this source http://ultrasql.blog.51cto.com/9591438/1694988
Installing the TOMCAT8 under CentOS