setenv.sh 不工作 [英] setenv.sh is not working

查看:37
本文介绍了setenv.sh 不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法设置 setenv.sh 文件工作.谁能帮我在服务器上设置.

I am unable to set setenv.sh file working. Can anyone help me to set it on server.

SETENVPATH="${CATALINA_BASE:-$CATALINA_HOME}" if [ -r "$SETENVPATH/bin/setenv.sh" ]; then   . "$SETENVPATH/bin/setenv.sh"  elif [ -r "$CATALINA_HOME/bin/setenv.sh" ]; then  . "$CATALINA_HOME/bin/setenv.sh" fi

它在本地机器上工作,但不在服务器机器上.

it's working on local machine but not in server machine.

推荐答案

我不完全明白你想用这段代码做什么,但基本上你只需要在 bin 目录中创建 setenv.sh 文件根据 catalina.sh 中的这段代码,您的 tomcat 安装将自动使用:

I don't exactly what you are trying to do with this piece of code, but basically you just have to create the setenv.sh file in the bin directory of your tomcat install, and it will be used automatically, as per this code piece from catalina.sh :

# Ensure that any user defined CLASSPATH variables are not used on startup,
# but allow them to be specified in setenv.sh, in rare case when it is needed.
CLASSPATH=

if [ -r "$CATALINA_BASE/bin/setenv.sh" ]; then
  . "$CATALINA_BASE/bin/setenv.sh"
elif [ -r "$CATALINA_HOME/bin/setenv.sh" ]; then
  . "$CATALINA_HOME/bin/setenv.sh"
fi

对于好的部分,您甚至不需要使其可执行.;-)

And for the nice part you don't even need to make it executable. ;-)

否则您能否提供更多详细信息,例如安装tomcat的路径和安装setenv.sh的位置,好吗?见.

Otherwise could you provide a bit more details, like the path where your tomcat is installed and the place where your setenv.sh is installed, please ? See you.

这篇关于setenv.sh 不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆