Build step ‘Execute shell‘ marked build as failure

shell 脚本远程调用执行如下:
/usr/bin/ssh 10.1.2.3 ‘/bin/bash /root/ReServer.sh‘
报错如下:
Build step ‘Execute shell‘ marked build as failure

本地执行是ok,怎么执行都报错,后来折腾了老半天,一步一步的打输出,发现:

原来是脚本在判断进程是否存在的同时,这个结束进程刚好有同样的匹配串!
ps -aux | grep "idiot" | grep -v grep | grep -v ‘$$‘ | awk ‘{print $2}‘
所以修改idiot,做精确匹配解决"sb idiot"

原文地址:https://blog.51cto.com/ckl893/2446413

时间: 2024-08-10 17:01:33

Build step ‘Execute shell‘ marked build as failure的相关文章

Build step 'Execute Windows batch command' marked build as failure

坑爹的Jenkis,在执行windows命令编译.NET项目的时候命令执行成功了,但是却还是报了这样一个错: Build step 'Execute Windows batch command' marked build as failure 综合了几个stackoverflow上的答案,原因如下: jenkins执行windows命令,若退出代码不为0 ,则jenkins会将构建标记为失败 我解决的方法:在bat脚本最后一行加上 exit 0 Build step 'Execute Windo

Pipeline build step with parameters

build step https://jenkins.io/doc/pipeline/steps/pipeline-build-step/#build-build-a-job 一个任务的执行触发,另外一个任务的执行,以代码的形式. build: Build a job Triggers a new build for a given job. job Name of a downstream job to build. May be another Pipeline job, but more

Jenkins Docker安装及Docker build step插件部署配置

Docker-build-step插件安装部署1.打开系统管理,插件管理,找到Docker build step插件,勾选选中,点击直接安装,安装完成后重启一下Jenkins容器:2.使用终端登录到B服务器,修改/usr/lib/systemd/system/docker.service 为: 将其中第11行的 ExecStart=/usr/bin/dockerd 替换为:ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2375 -H unix:///va

jenkins中通过execute shell启动的进程会被杀死的问题

在jenkins中配置自动更新部署项目时,如果采取用execute shell启动/关闭tomcat,会发现可以进行关闭tomcat, 但是无法启动tomcat,虽然构建会显示执行成功,但是查看进程,tomcat是没有启动的.这是因为Jenkins默认 会在Build结束后Kill掉所有的衍生进程.需要进行以下配置,才能避免此类情况发生: 1.重设环境变量build_id 在execute shell输入框中加入BUILD_ID=DONTKILLME,即可防止jenkins杀死启动的tomcat

TF42064: The build number already exists for build definition error in TFS2010

In TFS2008, deleting a build removes it from the database itself. If you delete a build called Build_20110423.1 or 1.0.0.1 from Build Explorer and trigger the build again then you will see that new builds starts with same number (Build_20110423.1 or

Errors occurred during the build. Errors occurred during the build. Errors running builder 'JavaScript Validator' on XXX

选择项目--右键Properties--Builders--如果有则取消第一项“JavaScript Validator”的勾. http://blog.csdn.net/error_case/article/details/21369337 Errors occurred during the build. Errors occurred during the build. Errors running builder 'JavaScript Validator' on XXX

Eclipse项目导入Android Stuio 配置出现 Timeout waiting to lock buildscript class cache for build file 'H:\studioproject\Generic_SN\build.gradle'

Eclipse项目导入Android Stuio 配置出现 Error:Timeout waiting to lock buildscript class cache for build file 'H:\studioproject\Generic_SN\build.gradle' (C:\Users\Administrator\.gradle\caches\2.2.1\scripts\build_81ep6udn3nlzszbotl32uedjz\ProjectScript\buildscri

compile,build和execute的区别

一个c程序的生成要经历以下步骤: 1.编写文本代码,生成c或cpp文件,这时候它还是文本的: 2.编译,就是compile,由c编译程序对你写的代码进行词法和句法分析,发现并报告错误,有错时编译不能通过.如若无错,则生成中间代码,扩展名为obj,此时它便是二进制的了: 3.连接,在汇编里称link,在c里叫生成,即build,它的作用是生成可执行的exe文件.由于一个程序的源码可由多个文件组成.这些文件在第二步 中分别编译,生成各自的目标文件,这一步的作用便是将这些obj文件,以及程序中需要的其

gtk+-3.21.4 static build step in windows XP

In recent days the weather is very hot Unable to sleep properly Under the state of daze research gtk3 static compiler. ------------------------------------------------------------------------------------------------------- build static libs ---------