The minute you think of giving up, think of the reason why you held on so long!
分类: LINUX
2014-05-21 12:58:49
系统、软件列表:
Centos5.6.x84_64
jdk-7u45-linux-x64.tar.gz
apache-tomcat-7.0.47.tar.gz
jdk1.7环境配置:
# tar zxf jdk-7u45-linux-x64.tar.gz
# cp -a jdk1.7.0_45 /data/soft/jdk1.7
# vim /etc/profile
######java env######
JAVA_HOME="/data/soft/jdk1.7"
CLASS_PATH="$JAVA_HOME/lib:$JAVA_HOME/jre/lib"
PATH=".:$PATH:$JAVA_HOME/bin"
export JAVA_HOME
export CLASS_PATH
export PATH
# source /etc/profile
# reboot
##查看jdk环境是否安装完成
# which java
/data/soft/jdk1.7/bin/java(输出正确的文件信息)
# java -version
java version "1.7.0_45"
Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)
tomcat7配置:
# tar zxf apache-tomcat-7.0.47.tar.gz
# cp -a apache-tomcat-7.0.47 /data/soft/tomcat7
# vim tomcat7/conf/server.xml
unpackWARs="true" autoDeploy="true">
prefix="localhost_access_log." suffix=".txt"
pattern="%h %l %u %t "%r" %s %b" />
# /data/soft/tomcat7/bin/catalina.sh configtest(检查server.xml文件)
# /data/soft/tomcat7/bin/catalina.sh start(启动tomcat)
# /data/soft/tomcat7/bin/catalina.sh stop(停止tomcat)