1. Tomcat之startup.sh
#判断操作系统
os400=false
case "`uname`" in
OS400*) os400=true;;
esac
# 取脚本名称
PRG="$0"
# 判断是否是软连接
while [ -h "$PRG" ] ; do
# 查看脚本信息
ls=`ls -ld "$PRG"`
# 获取真实脚本路径
link=`expr "$ls" : '.*-> \(.*\)$'`
# 是否是绝对路径
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`/"$link"
fi
done
# 取目录名称
PRGDIR=`dirname "$PRG"`
# 定义执行脚本
EXECUTABLE=catalina.sh
# Check that target executable exists
if $os400; then
# -x will Only work on the os400 if the files are:
# 1. owned by the user
# 2. owned by the PRIMARY group of the user
# this will not work if the user belongs in secondary groups
eval
else
# 判断是否可执行
if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then
echo "Cannot find $PRGDIR/$EXECUTABLE"
echo "The file is absent or does not have execute permission"
echo "This file is needed to run this program"
exit 1
fi
fi
# 执行catalina.sh start脚本 并附带所有参数
exec "$PRGDIR"/"$EXECUTABLE" start "$@"
————————————————
版权声明:本文为CSDN博主「QMCoder」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/qq_19457117/article/details/82533391
1. Tomcat之startup.sh的更多相关文章
- 【sh文件权限】无法启动tomcat -bash: ./startup.sh: Permission denied
今天在Linux上启动Tomcat,结果弹出:-bash: ./startup.sh: Permission denied 的提示. 这是因为用户没有权限,而导致无法执行, 用命令chmod 修改一下 ...
- linux下Tomcat 安装后执行startup.sh,出现– Cannot find …bin/catalina.sh
linux下Tomcat 安装后执行startup.sh,出现– Cannot find …bin/catalina.sh 是因为权限不够,执行以下命令就可以: chmod +x startup.sh ...
- linux中tomcat startup.sh出现commond not found
问题: 前些天,再Linux提交更新代码启动tomcat时报commond not found 过程: 查了下百度,http://code2care.org/2015/-bash:-startup.s ...
- CentOS7启动Tomcat报错:./startup.sh: Permission denied
错误信息:./startup.sh: Permission denied 执行./startup.sh,或者./shutdown.sh的时候, 报:Permission denied,因为是执行tom ...
- Docker - 容器中的tomcat如何使用startup.sh启动
网上大多介绍的catalina.sh启动,因为docker容器中,无法直接启动startup.sh. 解决方法: 编辑catalina.sh,找到 >> "$CATALINA_O ...
- Whats the difference between service tomcat ./startup.sh and ./catalina.sh run
stack overflow 给出的答案: catalina.sh run starts tomcat in the foreground, displaying the logs on the co ...
- centos7中启动tomcat提示bash: tomcat8.0.39/bin/startup.sh: 权限不够
问题描述: centos7中启动tomcat提示bash: tomcat8.0.39/bin/startup.sh: 权限不够 解决方案:先进入bin目录 [root@localhost/]# cd ...
- tomcat不能多次startup.sh,异常时直接,分析logs目录下的日志。
tomcat不能多次startup.sh,异常时直接干掉其进程. 分析logs目录下的日志.
- 关于LINUX权限-bash: ./startup.sh: Permission denied
关于LINUX权限-bash: ./startup.sh: Permission denied <script type="text/javascript"></ ...
随机推荐
- DevExpress GridControl 使用瀑布加载方式加载数据
从事winform开发已经快三年了,这三年中两年使用DevExpress控件进行winform系统开发,对Dev控件有自己的一些思考,下面就常用的表格控件GridControl的分页进行一些讨论. 在 ...
- 2019-2020-1 20199301《Linux内核原理与分析》第五周作业
第四章·系统调用的三层机制(上) 本章的重点在于用户态程序如何触发系统调用? 一.用户.内核.中断 IntelX86有四种不同的执行级别.Linux操作系统中只采用了其中的0和3两个特权级别,分别对应 ...
- 【Java】Unicode & UTF-8 & UTF-16 & UTF-32
Unicode Unicode(统一码.万国码.单一码)是计算机科学领域里的一项业界标准,包括字符集.编码方案等.Unicode 是为了解决传统的字符编码方案的局限而产生的,它为每种语言中的每个字符设 ...
- 接口中的JSON报文
原始报文: 请求报文: [ { "appNo" : "", "applicantCredentialCode" : "" ...
- [Schematics] 1. Copy and Manipulate Template
1. Create a src/my-component/files/src/app directory to hold your templates. mkdir -p src/my-compone ...
- 了解区块链&比特币
https://www.bilibili.com/video/av45247943 假如有ABCD四个比特币交易者,其中A交易给B者10个比特币(BTC),而这条信息要广播给其他所有的交易者知道. 假 ...
- RookeyFrame 线上 添加Model
线上添加好了模块,会在本地生成几个文件 类文件:Rookey.Frame.Web\Config\TempModel\Order_File.code DLL文件:Rookey.Frame.Web\bin ...
- yum和apt-get 软件包管理器的用法及区别
yum( Yellow dog Updater, Modified)是一个在Fedora和RedHat以及SUSE中的Shell前端软件包管理器. 一般来说著名的linux系统基本上分两大类: 1.R ...
- GDB十分钟教程【转载于网络爱好者】
本文写给主要工作在Windows操作系统下而又需要开发一些跨平台软件的程序员朋友,以及程序爱好者. GDB是一个由GNU开源组织发布的.UNIX/LINUX操作系统下的.基于命令行的.功能强大的程序调 ...
- Transformer 比较好的博客
1. https://www.jianshu.com/p/0c196df57323 细节理解: 2. https://zhuanlan.zhihu.com/p/44121378 3. https:// ...