关闭

TOMCAT-报错The BASEDIR environment variable is not defined correctly

标签: javatomcatapplicationoutputserverjdk
30596人阅读 评论(3) 收藏 举报
分类:
The BASEDIR environment variable is not defined correctly

启动tomcat时报错
The BASEDIR environment variable is not defined correctly
This environment variable is needed to run this program
 这坑爹的中间件,害的我搞了半天 根据提示开始排查环境变量设置
 
 以下是JDK 与tomcat的环境变量
 
[root@localhost bin]# more /etc/profile
 
JAVA_HOME=/usr/local/src/jdk1.6.0_32
JRE_HOME=$JAVA_HOME/jre
CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$JAVA_HOME/jre/lib/rt.jar
export JAVA_HOME CLASSPATH

CATALINA_1_BASE=/apache-tomcat-6.0.35/
CATALINA_1_HOME=/apache-tomcat-6.0.35/
export CATALINA_1_BASE  CATALINA_1_HOME

没啥错误,这害得我狠被动啊,无意中打了一个ls命了恍然大悟


[root@localhost bin]# ls -al 
总计 688
d-w------- 2 root root   4096 02-22 14:53 .
drwxr-xr-x 9 root root   4096 02-22 14:53 ..
--w------- 1 root root  22705 11-28 18:20 bootstrap.jar
--w------- 1 root root  11830 11-28 18:20 catalina.bat
--w------- 1 root root  17708 11-28 18:20 catalina.sh
--w------- 1 root root   2374 11-28 18:20 catalina-tasks.xml
--w------- 1 root root  24172 11-28 18:20 commons-daemon.jar
--w------- 1 root root 199623 11-28 18:20 commons-daemon-native.tar.gz
--w------- 1 root root   1342 11-28 18:20 cpappend.bat
--w------- 1 root root   2108 11-28 18:20 digest.bat
--w------- 1 root root   1689 11-28 18:20 digest.sh
--w------- 1 root root  55828 02-22 16:13 nohup.out
--w------- 1 root root   3150 11-28 18:20 setclasspath.bat
--w------- 1 root root   4114 11-28 18:20 setclasspath.sh
--w------- 1 root root   2108 11-28 18:20 shutdown.bat
--w------- 1 root root   1628 11-28 18:20 shutdown.sh
--w------- 1 root root   2109 11-28 18:20 startup.bat
--w------- 1 root root   2023 11-28 18:20 startup.sh
--w------- 1 root root  32277 11-28 18:20 tomcat-juli.jar
--w------- 1 root root 249259 11-28 18:20 tomcat-native.tar.gz
--w------- 1 root root   3479 11-28 18:20 tool-wrapper.bat
--w------- 1 root root   3472 11-28 18:20 tool-wrapper.sh
--w------- 1 root root   2113 11-28 18:20 version.bat
--w------- 1 root root   1632 11-28 18:20 version.sh


全部没有执行权限,赶紧赋权限
# chmod  777 -R bin/

[root@localhost bin]# nohup  sh catalina.sh  run & 
[1] 19004
[root@localhost bin]# nohup: appending output to “nohup.out”

[root@localhost bin]# tail -f nohup.out 
2012-2-22 16:26:47 org.apache.catalina.startup.HostConfig deployDirectory
信息: Deploying web application directory examples
2012-2-22 16:26:47 org.apache.coyote.http11.Http11Protocol start
信息: Starting Coyote HTTP/1.1 on http-8080
2012-2-22 16:26:47 org.apache.jk.common.ChannelSocket init
信息: JK: ajp13 listening on /0.0.0.0:8009
2012-2-22 16:26:47 org.apache.jk.server.JkMain start
信息: Jk running ID=0 time=0/15  config=null
2012-2-22 16:26:47 org.apache.catalina.startup.Catalina start
信息: Server startup in 466 m

OK了 tomcat终于起来了,坑爹啊 下次上传时一定要注意权限!



3
1
查看评论
发表评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场

The BASEDIR environment variable is not defined correctly This environment variable is needed to run

The BASEDIR environment variable is not defined correctly This environment variable is needed to run...
  • Sweblish
  • Sweblish
  • 2011-09-19 09:38
  • 4839

linux下tomcat启动报错The BASEDIR environment variable is not defined correctly

错误信息: The BASEDIR environment variable is not defined correctly  This environment variable is need...
  • Mchange
  • Mchange
  • 2014-02-20 16:16
  • 2171

mac下启动tomcat报错:The BASEDIR environment variable is not defined correctly

The BASEDIR environment variable is not defined correctly This environment variable is needed...
  • MyGameZone
  • MyGameZone
  • 2013-04-09 16:49
  • 2099

tomcat catalina_home已设置,仍然he CATALINA_HOME environment variable is not defined correctly

在tomcat目录下启动startup.bat时,The CATALINA_HOME environment variable is not defined correctly This env...
  • u011393781
  • u011393781
  • 2016-10-24 16:01
  • 1333

basedir="."表示当前路径,可以省略,在myeclipse中ant是可以调试的

  • seeds_home
  • seeds_home
  • 2012-01-05 10:45
  • 1867

tomcat basedir docBase path workdir

tomcat basedir docBase path workdirapache official documentsdocBase The Document Base (also know...
  • longyinyushi
  • longyinyushi
  • 2016-09-07 18:05
  • 735

The CATALINA_HOME environment variable is not defined correctly

1、问题 配置Apatch Tomcat过程报错: The CATALINA_HOME environment variable is not defined correctly.This envi...
  • liminled
  • liminled
  • 2014-01-10 16:32
  • 34589

tomcat启动一闪而过解决办法报错The CATALINA_HOME environment variable is not defined correctly

tomcat启动时一闪而过解决办法: 1.查找报错原因: 针对windows环境,liunx环境未进行测试 我的tomcat安装路径为:D:\apache-tomcat-7.0.57 进入cmd控制台...
  • zl453061296
  • zl453061296
  • 2016-07-22 12:19
  • 6393

The CATALINA_HOME environment variable is not defined correctly问题解决

今天配置Tomcat环境变量之后在命令提示符中进入到Tomcat安装目录的bin文件夹下,输入startup,之后提示错误,如下: The CATALINA_HOME environment var...
  • yunixiang
  • yunixiang
  • 2015-02-08 17:17
  • 2280

The CATALINA_HOME environment variable is not defined correctly

The CATALINA_HOME environment variable is not defined correctly 问题:今天配置tomcat运行环境时出现了下边的问题, The CA...
  • xu1314
  • xu1314
  • 2012-09-07 19:27
  • 12447
    个人资料
    • 访问:817095次
    • 积分:9016
    • 等级:
    • 排名:第2416名
    • 原创:137篇
    • 转载:45篇
    • 译文:9篇
    • 评论:44条
    简介
    此博客为笔者的DT工作记录,欢迎一起交流学习工作中的点滴,若博客文章观点存在原理的错误、纰漏,笔者非常欢迎各位不保留地指出
    最新评论