Tomcat启动报错:This file is needed to run this program

Tomcat版本为 8.5.29。

1.情景

kill调用tomcat进程后,重启tomcat报如下错误:

Cannot find /usr/local/apache-tomcat-8.5.29/bin/setclasspath.sh
This file is needed to run this program

2.解决方法

编辑 catalina.sh,发现前两行多了如下内容:

export CATALINA_BASE=$CATALINA_BASE2
export CATALINA_HOME=$CATALINA_HOME2

于是注释掉这两行,重启tomcat成功。至于为什么多了这两行,不晓得原因。怎么发现这两行的呢,对比了下相同版本的tomcat的 catalina.sh

原文地址:https://www.cnblogs.com/xbq8080/p/9185239.html

时间: 2024-08-06 23:42:36

Tomcat启动报错:This file is needed to run this program的相关文章

Tomcat启动报错[org.apache.struts2.dispatcher.Dispatcher]Dispatcher initialization failed

Tomcat启动报错: [org.apache.struts2.dispatcher.Dispatcher]Dispatcher initialization failed Unable to load configuration. - bean - jar:file:/E:/SoftwareDevelopment/Software/Eclipse4.3/eclipse-jee-kepler-SR1-win32-x86_64/Workspace/.metadata/.plugins/org.ec

Tomcat启动报错java.net.AbstractPlainSocketImpl(java/net/AbstractPlainSocketImpl.java:178:-1)Struts在网络复杂情况下启动报错解决办法

SSH项目 在网络复杂的情况(具体规律未知)下,Tomcat启动时,报如下错误: [ERROR] 2014-08-12 14:52:58,484 [org.apache.struts2.dispatcher.Dispatcher :27] - Dispatcher initialization failedUnable to load configuration. - Class: java.net.AbstractPlainSocketImplFile: AbstractPlainSocket

Tomcat启动报错:严重: StandardServer.await: create[8005] java.net.BindException: Cannot assign requested address

org.apache.catalina.core.StandardServer await        SEVERE: StandardServer.await: create[8005]:        java.net.BindException: Cannot assign requested address java.net.BindException: Cannot assign requested address        at java.net.PlainSocketImpl

tomcat启动报错,找不到相应的 queue,从而引发内存泄漏

tomcat启动报错,无法创建 bean listenerStatusChangeDealHandler, no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost 从启动日志来看,有时候仅会看到内存泄漏,而没有与queue相关的日志,非常easy走错方向. 依照 http://blog.csdn.net/wangjunjun2008/article/details/23375501 的方法能够看到具体日志,从而确定报错原因 tomcat

Tomcat启动报错org.springframework.web.context.ContextLoaderListener类配置错误——SHH框架

SHH框架工程,Tomcat启动报错org.springframework.web.context.ContextLoaderListener类配置错误 1.查看配置文件web.xml中是否配置.org.springframework.web.context.ContextLoaderListener在web.xml配置文件中已经配置 2.查看工程是否添加此jar包,org.springframework.web.context.ContextLoaderListener的jar包为spring

tomcat启动报错,找不到对应的 queue,从而引发内存泄漏

tomcat启动报错,无法创建 bean listenerStatusChangeDealHandler, no queue 'STOCK.NOTIFY_CHANGE.INTER.CACHE.QUEUE' in vhost 从启动日志来看,有时候仅会看到内存泄漏,而没有与queue相关的日志,很容易走错方向. 按照 http://blog.csdn.net/wangjunjun2008/article/details/23375501 的方法可以看到详细日志,从而确定报错原因 tomcat启动报

Cannot find tomcat目录/bin/setclasspath.sh This file is needed to run this program

首先如果直接使用 root 用户来启动 tomcat 的话,是可以正常启动的. 但是我们在 Linux 中使用普通用户启动 tomcat 报了如下错误 Cannot find /developer/apache-tomcat-8.5.50/bin/setclasspath.sh This file is needed to run this program 原因是没有在 setclasspath.sh 上设置 JAVA_HOME 和 JRE_HOME. 解决办法: 打开 setclasspath

windows tomcat 启动报错TOMCAT JAVA_HOME or JRE_HOME environment variable is not defined correctly

问题描述: TOMCAT JAVA_HOME or JRE_HOME environment variable is not defined correctly 报错信息如下:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined At least one of these environment variable is needed to run this program;提示找不到java_home各jre

tomcat启动报错:java.net.BindException: Permission denied <null>:80

1,启动报错显示 [org.springframework.web.servlet.DispatcherServlet]FrameworkServlet 'springMvc': initialization completed in 382 ms Jun 01, 2015 6:39:06 PM org.apache.coyote.http11.Http11Protocol start SEVERE: Error starting endpoint java.net.BindException: