标签:启动 5.x server tools.jar ase 安装路径 pack minion local
TomcatJDK:Java开发工具包
JRE: Java运行环境
SDK:辅助开发工具(短信商之列的)
J2EE:企业应用
J2SE:标准应用
J2ME:手机
中间件:tomcat resin jboss weblogic websphere
查看是否安装jdk
[root@minion ~]# rpm -qa|grep jdk
java-1.7.0-openjdk-1.7.0.45-2.4.3.3.el6.x86_64
java-1.6.0-openjdk-1.6.0.0-1.66.1.13.0.el6.x86_64
查找jdk安装路径,配置环境变量
[root@minion ~]# rpm -ql java-1.7.0-openjdk-1.7.0.45-2.4.3.3.el6.x86_64
/etc/.java
/etc/.java/.systemPrefs
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libsaproc.so
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libsctp.so
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libsplashscreen.so
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libunpack.so
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libverify.so
/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64/jre/lib/amd64/libzip.so
设置环境变量
vim /etc/profile
#set java environment
JAVA_HOME=/usr/lib/jvm/java-1.7.0-openjdk-1.7.0.45.x86_64
JRE_HOME=$JAVA_HOME/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
让修改生效
[root@localhost java]# source /etc/profile
修改tomcat配置文件,然后把开发的代码放到/usr/local/tomcat/ROOT下
vim /etc/tomcat/server.xml
<Host name="localhost" appBase="/usr/local/tomcat"
unpackWARs="true" autoDeploy="true">
mkdir /usr/local/tomcat/ROOT -P
vim index.jsp
Hello,tomcat home! The time is <%= new java.util.Date() %>
启动apache服务
service tomcat start
浏览器访问
http://192.168.56.21:8080/
标签:启动 5.x server tools.jar ase 安装路径 pack minion local
原文地址:http://blog.51cto.com/13491150/2062108