红联Linux门户
Linux帮助

提示:cannot touch ‘/usr/local/tomcat8/logs/catalina.out’

发布时间:2017-03-02 10:08:46来源:linux网站作者:柱子89
linux安装完tomcat8后,进入其目录/usr/local/tomcat8/bin/,运行startup.sh出现错误:
touch: cannot touch ‘/usr/local/tomcat8/logs/catalina.out’:No such file or directory
 
其解决办法如下:
自己建立目录:
mkdir /usr/local/tomcat8/logs
重新运行,问题解决。
 
除此之外要配置tomcat和jdk的关联,编辑startup.sh,最后加入:
JAVA_HOME=/usr/local/jdk/jdk1.8.0_05
JRE_HOME=/usr/local/jdk/jdk1.8.0_05/jre
PATH=$JAVA_HOME/bin:$JRE_HOME:$PATH
CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
修改权限:
chmod -R 777 /usr/local/tomcat8
 
本文永久更新地址:http://www.linuxdiyf.com/linux/28825.html