我正在尝试使用Jenkins来执行Weblogic重新启动管理和手动服务器。因此,我在Build部分中使用了Execute Shell选项来运行来启动Admin服务器,但是在<Server started in RUNNING mode>行和next Unix命令未执行之后,日志就被卡住了。
我试着在shell中使用一个函数来得到这样的条件,比如
function check()
{
key="<Server started in RUNNING mode>"
##kill the process after grepping the key
done
我正在运行两个脚本
# Script 1
nohup sh {command} &
并且nohup.out拥有所有日志的详细信息(对于脚本1)
# Script 2
nohup sh {command} > {log_path} 2>&1 &
但是nohup.out仅具有如下所列的有限日志(对于脚本2),
## Script2 output
Shutdown message has been posted to the server.
Server shutdown may take a while - check logfiles for c
我通过crontab执行script1.sh。
script1.sh
echo "Crontab is executing this script."
echo "Some code is running here."
cd cron
./script2.sh
“script1.sh”正在调用“script2.sh”。
'script2.sh‘
echo "Exceuting script2."
echo "log of script3.sh is inserting in nohup.out file."
nohup s
我正试图设置一个新工作,但由于某种原因,它在开始后立即停止。
我的价格是6.5美分
这是我的档案:
/ect/init/test-daemon.conf
start on startup
stop on shutdown
respawn
script
sudo -u root php -f /usr/share/test_daemon.php
end script
/usr/share/test-daemon.php
<?php
// The worker will execute every X seconds:
$seconds = 2;
//