1、windows下:
修改 tomcat/bin/setclasspath.bat
在
rem Otherwise either JRE or JDK are fine
之前加上
set JAVA_HOME = C:…. jdk路径
set JRE_HOME = C:….\jre Jre路径
2、linux环境下
修改tomcat/bin/setclasspath.sh
在
//First clear out the user classpath
CLASSPATH=
下面添加上
export JAVA_HOME=/home/tool/jdk1.6.0_18 –jdk路径
export JRE_HOME=/home/tool/jdk1.6.0_18/jre –jre路径
保存,重新启动tomcat即可..