centos7环境下配置tomcat
程序员文章站
2022-05-10 13:06:48
...
[aaa@qq.com local]# cp jdk-7u79-linux-x64.gz /usr/local/ //将jdk复制到/usr/local/目录下
[aaa@qq.com local]# cd /usr/local/ //进入/usr/local/目录
[aaa@qq.com local]# tar -zxvf jdk-7u79-linux-x64.gz //解压jdk安装包
[aaa@qq.com local]# ln -s jdk1.7.0_79 jdk //设置jdk软连接
[aaa@qq.com local]# vim /etc/profile //修改环境变量,加入下面内容在文件尾
export JAVA_HOME=/usr/local/jdk
export PATH=$JAVA_HOME/bin:$PATH
[aaa@qq.com ~]# source /etc/profile //生效环境变量
[aaa@qq.com ~]# java -version //测试java环境版本
java version "1.7.0_79"
Java(TM) SE Runtime Environment (build 1.7.0_79-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.79-b02, mixed mode)
java环境安装完毕
[aaa@qq.com tmp]# cp apache-tomcat-6.0.20.tar.gz /usr/local/ //将tomcat复制到/usr/local目录下
[aaa@qq.com local]# tar -zxvf apache-tomcat-6.0.20.tar.gz //解压tomcat安装包
[aaa@qq.com local]# ln -s apache-tomcat-6.0.20.tar.gz tomcat //设置tomcat软连接
[aaa@qq.com tmp]# cd /usr/local/
[aaa@qq.com local]# vim /etc/profile //修改环境变量,加入下面内容在文件尾
export TOMECAT_HOME=/usr/local/tomcat
[aaa@qq.com tomcat]# /usr/local/tomcat/bin/startup.sh //启动tomcat
Using CATALINA_BASE: /usr/local/tomcat
Using CATALINA_HOME: /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME: /usr/local/jdk
出现tomcat页面,tomcat服务器安装成功
[aaa@qq.com tomcat]# cd /usr/local/
[aaa@qq.com local]# vim linux.xml //新建linux.xml网页文件
[aaa@qq.com local]# cd /usr/local/tomcat/webapps/
[aaa@qq.com webapps]# mkdir text
[aaa@qq.com webapps]# cp /usr/local/linux.xml /usr/local/tomcat/webapps/text/
[aaa@qq.com webapps]# cp -r /usr/local/tomcat/webapps/ROOT/WEB-INF/ /usr/local/tomcat/webapps/text/
[aaa@qq.com webapps]# /usr/local/tomcat/bin/shutdown.sh
Using CATALINA_BASE: /usr/local/tomcat
Using CATALINA_HOME: /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME: /usr/local/jdk
[aaa@qq.com webapps]# /usr/local/tomcat/bin/startup.sh
Using CATALINA_BASE: /usr/local/tomcat
Using CATALINA_HOME: /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME: /usr/local/jdk
tomcat服务器下的网页搭建成功
下一篇: ansible 小试牛刀
推荐阅读
-
红旗Linux4.1下安装配置Apahce+Tomcat+PHP+mySQL+vsFTPd
-
windows下zendframework项目环境搭建(通过命令行配置)_php技巧
-
windows下配置php5.5开发环境及开发扩展,windowsphp5.5
-
如何在Windows 下配置 PHP 环境教程
-
tomcat下配置通过端口直接访问web应用
-
Mac OS下配置PHP+MySql环境
-
php在apache环境下实现gzip配置方法_PHP
-
phpmyadmin 下载 MAC OS X环境下配置APACHE+PHP+MYSQL+PHPMYADMIN
-
Windows7下PHP开发环境安装配置图文方法_PHP教程
-
在IIS7.0下面配置PHP 5.3.2运行环境的方法_PHP