美文网首页
tomcat 安装

tomcat 安装

作者: JepWei | 来源:发表于2022-07-13 00:41 被阅读0次
cd /usr/local
mkdir tomcat
tar -xvf apache-tomcat-9.0.56.tar.gz -C /usr/local/tomcat

vim /etc/profile
export CATALINA_BASE=/usr/local/tomcat/apache-tomcat-9.0.56/
export PATH=$CATALINA_BASE/bin:$PATH

source /etc/profile


cd /usr/local/tomcat/apache-tomcat-9.0.56/bin
./startup.sh

firewall-cmd --add-port=8080/tcp --permanent
firewall-cmd --reload

jdk

mkdir -p /usr/local/java
cd /usr/local/java
curl -O http://download.Oracle.com/otn-pub/java/jdk/7u79-b15/jdk-7u79-linux-x64.tar.gz


vi /etc/profile
#set java environment
JAVA_HOME=/usr/local/java/jdk1.7.0_79
JRE_HOME=/usr/local/java/jdk1.7.0_79/jre
CLASS_PATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$JRE_HOME/lib
PATH=$PATH:$JAVA_HOME/bin:$JRE_HOME/bin
export JAVA_HOME JRE_HOME CLASS_PATH PATH

source /etc/profile

java -version



相关文章

网友评论

      本文标题:tomcat 安装

      本文链接:https://www.haomeiwen.com/subject/qsllbrtx.html