从官网 www.apache.org 下载Tomcat 的相应Linux下的版本,本文以tomcat-5.5.33为例。 1) 解压成文件夹,视具体的文件格式而定。 2) $ vi /etc/profile #用vi编辑器打开该文件进行编辑(添加环境变量) 3) 现在在终端运行命令: 备注:安装过程中遇到几个问题 问题1 : can't find the file '' 在网络上找到如下解释,意思就是需要再设置 Then all you need to do is to include the complete paths for the BASEDIR and CATALINA_HOME variables in the files and respectively. This should be done even if CATALINA_HOME has been defined and exported previously on the command line and/or in /etc/profile as well. Moreover, this error message persists even though the file is present in Tomcat's bin directory.
然后在文件的最尾部加入以下代码:
CATALINA_HOME=/tools/apache-tomcat-5.5.33 #(tomcat版本视自己的安装版本而定 )
export CATALINA _HOME
保存退出.
$ /tools/tomcat*/bin/startup.sh #开启TOMCAT服务器
然后打开浏览器,输入http://localhost:8080或者 http://127.0.0.1:8080 如果你看到那只可爱的小猫了,就证明安装成功了!
$ echo "BASEDIR=/path/to/tomcat" >> # /path/to 表示你的具体目录
$ echo "CATALINA_HOME=/path/to/tomcat" >>
但是在设置了如上的设置后,使用export命令查看环境变量,发现CATALINA_HOME仍没有改变,所以就是使用如下命令做修改
$ export CATALINA_HOME="/home/owner/tomcat-5.5.33"
问题2: 找不到JAVA_HOME 或者 JRE,由于未设置,因而Tomcat无法找到相应的环境变量,而无法启动 解决方法很简单,在终端中:
$ export JAVA_HOME="/home/owner/tools/jdk1.6.0_26"
Linux下Tomcat安装与启动
原创
©著作权归作者所有:来自51CTO博客作者jason69181的原创作品,请联系作者获取转载授权,否则将追究法律责任
下一篇:我的友情链接
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
vSphere与NVIDIA 2024年10月下载
vSphere 8.0u3d、7.0u3t、vGPU 17.4/16.8
html VMware 虚拟化 -
tomcat 8.0下载
tomcat 8.0下载官网:https://tomcat.apache.org/download-80.cgi选择合适版本
tomcat java tomcat8 官网 apache
















